Giter VIP home page Giter VIP logo

paradigm-client's People

Contributors

ameliechatelain avatar cthiriet avatar famoreau avatar guipenedo avatar iacolippo avatar othmanhicheur avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

paradigm-client's Issues

`use_session` is not properly used as default by create_from_objects

This snippet:

from paradigm_client.remote_model import RemoteModel
from paradigm_client.request import CreateParameters, CreateRequest


host = "https://llm.lighton.ai"
model = RemoteModel(host, model_name="llm-mini")

requests = CreateRequest(text="Hello I am")
response = model.create_from_objects(requests)

generates an error response:
1 validation error for CreateRequest\nuse_session\n value could not be parsed to a boolean (type=type_error.bool)
while changing the last line to

response = model.create_from_objects(requests, use_session=True)

works fine.

For some reason, the default value of use_session is interpreted as an extra param in the request?

Make` MAX_SEQ_LEN` in request.py editable

In request.py there is a constant

MAX_SEQ_LEN = 2048

which is used in the @validator of the parameters.

If using a model with longer context length, this becomes a problem to use.

I've tried overriding the validator with a children class, but it doesn't seem to be possible with pydantic v1 (it's kinda possible with the v2, when using root_validator instead of validator)

Perhaps the best option would be to have the the MAX_SEQ_LEN load from an env variable (and default to 2048).

Happy to make a PR

Default AWS region missing

If I don't have an aws region specified, the api throws an error. We should allow passing args to it.

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.