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

Remove extra cassettes #337

Closed
wants to merge 19 commits into from
Closed

Remove extra cassettes #337

wants to merge 19 commits into from

Conversation

mskarlin
Copy link
Collaborator

@mskarlin mskarlin commented Sep 9, 2024

see title

mskarlin and others added 19 commits August 29, 2024 11:24
* add agentic workflow module and cli

* update pyproject.toml and split google into its own import

* remove unused import

* update default search chain

* Update __init__.py

* Update search.py

* move reqs into pyproject.toml, addressing PR comments

* rename search_chain to openai_get_search_query

* remove get_llm_name

* move table_formatter to helpers.py

* Update paperqa/agents/main.py

Co-authored-by: James Braza <[email protected]>

* Update paperqa/agents/main.py

Co-authored-by: James Braza <[email protected]>

* Update paperqa/agents/main.py

Co-authored-by: James Braza <[email protected]>

* Update paperqa/agents/docs.py

Co-authored-by: James Braza <[email protected]>

* Update paperqa/types.py

Co-authored-by: James Braza <[email protected]>

* rename compute_cost to compute_total_model_token_cost

* remove stream_answer

* rename to stub_manifest, and use Path for all paths

* Update paperqa/llms.py

Co-authored-by: James Braza <[email protected]>

* move SKIP_AGENT_TESTS = False

* nix _ = assignments

* add test comments

* types in conftest.py

* split libs into llms

* link openai chat timeout to query.timeout

* Update paperqa/agents/__init__.py

Co-authored-by: James Braza <[email protected]>

* logging revamp and renaming

* Update tests/test_cli.py

Co-authored-by: James Braza <[email protected]>

* Update tests/test_cli.py

Co-authored-by: James Braza <[email protected]>

* move vertex import to func call, add docstring to SupportsPickle

* docstring

* remove _ =

* remove bool return type from set

* update gitignore

* add config attribute to baase LLMModel class

* replace get_current_settings -> get_settings

* replace get_current_settings -> get_settings

* PR simplifications

* remove all stream_* functions

* avoid modifying the root logger

* re-organize logger import location

* move hashlib into utils

* refactor strip_answer into Answer object

* label circular imports

* ensure absolute paths are used in index name

* limit select to be used only when DOI is not present in crossref

* Update paperqa/agents/search.py

Co-authored-by: James Braza <[email protected]>

* Update paperqa/agents/search.py

Co-authored-by: James Braza <[email protected]>

* Update paperqa/agents/search.py

Co-authored-by: James Braza <[email protected]>

* Update paperqa/agents/search.py

Co-authored-by: James Braza <[email protected]>

* Update paperqa/agents/models.py

Co-authored-by: James Braza <[email protected]>

* reconfigure logging to not prevent propagation

* remove newlines in the current year

* use required fields as a subset

* replace . with Path.cwd()

---------

Co-authored-by: James Braza <[email protected]>
* add unpaywall provider

* remove unused clean query method, update test cassettes to use [email protected]
…tests (#311)

* making SearchIndex.fields a list

* replace ids with md5 sum

* rename stub for test_agent_sharing_state

* run github actions on PRs into release branches too

* ruff formatting

* remove nested quotes for <3.12

* added staging data into tests; reimplemented tests to avoid downloads and keep consistent hashes; aded env vars to test.yaml

* conftest removes extension from near match filenames

* add match_on for sequential runs since they may be out of order

* refresh casettes

* replace deprecated pytest-vcr with pytest-recording

* change matching criteria

* set unpaywall email for CI

* try explicit conditions on cassette files, set the cassette dir

* removed vcr for sequential client tests

* add fixture to ensure that log levels are reset

* added cassettes back in for sequential tests after determining it was a log level failure

* limit cli logger mutation to avoid clobbering other library defaults

---------

Co-authored-by: Siddharth Narayanan <[email protected]>
Large refactor to decouple Docs, LLMs, and Config.

    Moves to centralized config that can be loaded from package data or defaults. This changes many function calls so that they pass config as an object or name of a config object.
    Removed doc_match and doc_index - these were only sometimes useful and not really part of current usage. We can add back if needed, but just complicated things.
    Removed the unnecessary complicated get_callbacks factories. Now, callbacks can have a kwarg of name to get access to name of chain being called.
    Switched to contextvars for setting answer_id in LLMResults so that we do not need to have so much back and forth for callbacks.
    Deferred updates to Answer objects until end of functions so that retrying is possible (except token counts)
    Generally moved all config out of Docs, except LLMModel which will be fixed in port to litellm



Co-authored-by: Michael Skarlinski <[email protected]>
Co-authored-by: James Braza <[email protected]>
Co-authored-by: mskarlin <[email protected]>
I accidentally put an extra struct=True and broke everything
Co-authored-by: Michael Skarlinski <[email protected]>
Co-authored-by: James Braza <[email protected]>
@mskarlin mskarlin closed this Sep 9, 2024
@jamesbraza jamesbraza deleted the remove-extra-cassettes branch September 9, 2024 22:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants