Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Cohere API as available language model #395

Open
wants to merge 30 commits into
base: master
Choose a base branch
from

Commits on Mar 10, 2023

  1. aux: add egg-info to gitignore

    Could consider using standard gitignore file for python in full rewrite, e.g. https://github.com/github/gitignore/blob/main/Python.gitignore
    rdnfn committed Mar 10, 2023
    Configuration menu
    Copy the full SHA
    bf584d4 View commit details
    Browse the repository at this point in the history
  2. aux: add vscode to gitignore

    rdnfn committed Mar 10, 2023
    Configuration menu
    Copy the full SHA
    e49d4ac View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    8550aaa View commit details
    Browse the repository at this point in the history
  4. feat: add rough sketch of cohere lm

    Not yet functional or tested.
    rdnfn committed Mar 10, 2023
    Configuration menu
    Copy the full SHA
    6616b9a View commit details
    Browse the repository at this point in the history

Commits on Mar 11, 2023

  1. Configuration menu
    Copy the full SHA
    384a45a View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    89ff0c3 View commit details
    Browse the repository at this point in the history

Commits on Mar 13, 2023

  1. Configuration menu
    Copy the full SHA
    6876c47 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    8b5f270 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    1f2c3cd View commit details
    Browse the repository at this point in the history

Commits on Mar 14, 2023

  1. refactor: minor tweaks

    rdnfn committed Mar 14, 2023
    Configuration menu
    Copy the full SHA
    f5c13a5 View commit details
    Browse the repository at this point in the history
  2. add cohere lm to model registry

    rdnfn committed Mar 14, 2023
    Configuration menu
    Copy the full SHA
    f3188ed View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    c018bd4 View commit details
    Browse the repository at this point in the history

Commits on Mar 22, 2023

  1. Configuration menu
    Copy the full SHA
    7597f31 View commit details
    Browse the repository at this point in the history
  2. feat: use cohere retry tools

    rdnfn committed Mar 22, 2023
    Configuration menu
    Copy the full SHA
    5de956b View commit details
    Browse the repository at this point in the history
  3. fix: ensure currect comparison made for is_greedy

    Also ensures empty context tokens work
    rdnfn committed Mar 22, 2023
    Configuration menu
    Copy the full SHA
    938af35 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    dfe032e View commit details
    Browse the repository at this point in the history
  5. fix: add newline instead of empty context and fix old api call

    Note that the API does not accept empty context, thus adding a newline to get generations
    with empty context, ideally this doesn't affect distribution much
    rdnfn committed Mar 22, 2023
    Configuration menu
    Copy the full SHA
    ed15f7a View commit details
    Browse the repository at this point in the history

Commits on Mar 24, 2023

  1. feat: update tokenizer to fully rely on API

    This replaces old transformer tokenizer with API calls.
    Also removes tokenisation were not strictly necessary.
    rdnfn committed Mar 24, 2023
    Configuration menu
    Copy the full SHA
    ab0c775 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    fac5035 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    fe5d8f2 View commit details
    Browse the repository at this point in the history
  4. fix: remove update huggingface.py for pre-commit error

    Removes one of two newlines at end of file
    rdnfn committed Mar 24, 2023
    Configuration menu
    Copy the full SHA
    ee012b1 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    e2985c5 View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    e85b3c7 View commit details
    Browse the repository at this point in the history

Commits on Mar 25, 2023

  1. Configuration menu
    Copy the full SHA
    07d63bb View commit details
    Browse the repository at this point in the history
  2. feat: allow to disable is_greedy computation

    This also removes old logic where newline was added
    to context. Disabling is greedy computation helps when dealing with
    empty context data.
    rdnfn committed Mar 25, 2023
    Configuration menu
    Copy the full SHA
    3044f47 View commit details
    Browse the repository at this point in the history
  3. test: add new checks for empty context

    With and without disabling greedy computation.
    rdnfn committed Mar 25, 2023
    Configuration menu
    Copy the full SHA
    92e32c8 View commit details
    Browse the repository at this point in the history

Commits on Apr 4, 2023

  1. feat: add custom loglikelihood_rolling implementation

    unlike the gpt3 model we need a custom loglikelihood_rolling
     implementation
     because we don't know the eot token, thus we use a separate prefix token.
     Preferred setting separate prefix token to avoid confusion.
    
     This also adds the capability to
     _loglikelihood_tokens to use tokens instead of str requests
    rdnfn committed Apr 4, 2023
    Configuration menu
    Copy the full SHA
    0ceea05 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    11b2368 View commit details
    Browse the repository at this point in the history

Commits on Apr 23, 2023

  1. Configuration menu
    Copy the full SHA
    5383692 View commit details
    Browse the repository at this point in the history

Commits on Jun 21, 2023

  1. fix: prevent too long contexts if prefix is added

    also prevent tokenisation of strings that too long
    rdnfn committed Jun 21, 2023
    Configuration menu
    Copy the full SHA
    8aafdda View commit details
    Browse the repository at this point in the history