-
Notifications
You must be signed in to change notification settings - Fork 50
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
[llm unify 2/n] Implement llm_map(_elements) and move extract_entity to it. #1126
Merged
Merged
Changes from 43 commits
Commits
Show all changes
49 commits
Select commit
Hold shift + click to select a range
c2a8cfa
add prompt base classes and ElementListPrompt
HenryL27 21a115a
override .instead in ElementListPrompt to store net-new keys in self.…
HenryL27 f94da80
add ElementPrompt and StaticPrompt
HenryL27 b73c162
add unit tests for prompts
HenryL27 17b2163
forgot to commit this
HenryL27 5d145d5
address pr comments; flatten properties with flatten_data
HenryL27 7fa2ff1
support multiple user prompts
HenryL27 abf9b0b
rename instead to set
HenryL27 9909c7e
Merge branch 'main' of github.com:aryn-ai/sycamore into hml-llm-unify
HenryL27 2d1315b
add LLMMap and LLMMapElements transforms
HenryL27 1853d51
Merge branch 'main' of github.com:aryn-ai/sycamore into hml-llm-unify
HenryL27 5e86e56
move llm implementations to use RenderedPrompts
HenryL27 27581ef
also this guy
HenryL27 739b672
add docset methods
HenryL27 73d9bdd
docstrings
HenryL27 ed8785e
add llm_map unit tests
HenryL27 523d6e3
fix bedrock tests and chaching
HenryL27 e1b3206
fix anthropic and bedrock ITs
HenryL27 6500e1c
adjust caching to handle pydantic class response format properly
HenryL27 f50032d
fix base llm unit tests
HenryL27 c3c7ea8
adjust all testing mock llms to updated llm interface
HenryL27 ffaaf0f
deprecate extract entity and implement it with llm_map
HenryL27 d71cf1a
add context_params decorator to llm_map
HenryL27 4225e11
revert extract_entity docset method re-implementation
HenryL27 0d39b27
add initial support for prompts that generate a sequence of rendered …
HenryL27 0b5ded4
add stuff to EntityExtractor/OpenAIEntityExtractor to convert to LLMMap
HenryL27 a52f7c2
make docset.extract_entity construct an LLMMap from its entity_extractor
HenryL27 3a9ac3c
get extract entity working with tokenizer and token limit
HenryL27 befc3d0
get all extract_entity unit tests passing
HenryL27 8bf42d5
fix llm_map_elements to deal with postprocess index
HenryL27 d7ff1eb
add postprocess_fn unit tests for llm_map
HenryL27 a7a2cc0
ruff complaint
HenryL27 ebf721e
fix docset unittests
HenryL27 0bd2a45
move a bunch of stuff back to llm.generate_old. This includes the act…
HenryL27 95cbaaf
move more stuff back to llm.generate_old
HenryL27 ea7f0e6
fix the last few mocks
HenryL27 2e51ee1
Merge branch 'main' of github.com:aryn-ai/sycamore into hml-llm-unify
HenryL27 57a4e4b
ruff linelength
HenryL27 a312ba3
mypy!!!
HenryL27 ebde879
type: ignore + line length is tricky
HenryL27 ff5efdc
fix generate_old with SimplePrompts
HenryL27 370e2b7
set openai system role name to system instead of developer like their…
HenryL27 98ce6a0
address simple pr comments
HenryL27 1789409
pickle stuff in llm caching path bc not everything is jsonifiable
HenryL27 8b6f085
rewrite llm_map to deal with iterative prompting better
HenryL27 763acc5
add a b64encode-to-str to cache bc you can't put bytes in json either
HenryL27 0331866
fix llm its to mimic the _llm_cache_set/get pickle/unpickle operations
HenryL27 dfb7540
fix docstrings
HenryL27 f7c06e7
oops bad type signature
HenryL27 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is the plan also to deprecate extract_properties?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the plan is to deprecate just about everything on my sprint tasks