Skip to content

Upgrade cohere v4 → v7 and refresh outdated dev-dependency pins #95

Description

@jhamon

Problem

pyproject.toml pins cohere = "^4.37" while the current major is 7.x — three majors behind, and the v5 rewrite changed the client API surface, so pinecone_text/dense/cohere_encoder.py likely needs call-site updates. Several dev deps are also behind: pytest = "^7.2.1" (8.x current), black = "^23.1.0" (24.x+ current). (Relates to existing issue #61 "Handle Cohere embedding models".)

Proposed fix & acceptance

  • Upgrade cohere to current 7.x; adapt CohereEncoder to the new client API (consult cohere's migration notes); ensure tests/unit/test_cohere_encoder.py and tests/system/test_cohere_encoder.py pass.
  • Bump pytest and black to current majors; re-run black --check and the suite (black 24 may reformat).
  • Acceptance: suite green on the full matrix; no beta/EOL pins; call sites match the new cohere API.

Blast radius

risky (major SDK upgrade with API changes + a formatter major that can touch many files).

Depends on

#92 (reproducible lockfile) and the existing tests/ suite as the safety net — do not attempt before install is reproducible.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

maintenanceRepo maintenance sweep

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions