Code Monkey home page Code Monkey logo

Comments (2)

efriis avatar efriis commented on September 14, 2024

Hey @Cutwell ! This isn't currently-supported behavior. If you want to switch out the path, there are a few more things to note!

All packages are installed as editable "path" dependencies, so you'll have to re-install the new package (you may want to remove the old one before renaming too).

The from x import chain x is going to be the inner folder within the package (same as all python packages), so you'll need to make sure your x is equal the python path within the inner folder.

app/
packages/
  rag/
    pyproject.toml
    **x/**
      __init__.py
      chain.py

The other option you have is to langchain app add rag-conversation --api-path=rag to "add" the package at a custom path.

Let me know how else I can help!

from langserve.

Cutwell avatar Cutwell commented on September 14, 2024

Hi @efriis , thanks for your response.

I think we can achieve the desired result with existing functionality and some manual steps..

  1. Copy the package component to elsewhere in my repository
  2. Remove the langserve component with langchain app remove my-app
  3. Rename the copied component appropriately
  4. Re-add the component from a local sourcepath (langchain app add ...?)
  5. Tidy up the copied component and resume development with the newly created / renamed package component

This works up until step 4 - I can create a new LangServe app using a local component as a package using langchain app new my-langserve --package $PWD/my-app, but it's unclear how to do this with an existing langserve project.

from langserve.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.