Commit Graph

12709 Commits

Author SHA1 Message Date
Chester Curme
1dafe0e2e2 increment langchain version langchain==0.3.18rc2 2025-02-06 08:13:03 -05:00
Chester Curme
26a75d9386 Merge branch 'master' into cc/migrate_uv
# Conflicts:
#	libs/community/extended_testing_deps.txt
2025-02-06 08:07:33 -05:00
Vincent Emonet
0ac5536f04 community: add support for using GPUs with FastEmbedEmbeddings (#29627)
- **Description:** add a `gpu: bool = False` field to the
`FastEmbedEmbeddings` class which enables to use GPU (through ONNX CUDA
provider) when generating embeddings with any fastembed model. It just
requires the user to install a different dependency and we use a
different provider when instantiating `fastembed.TextEmbedding`
- **Issue:** when generating embeddings for a really large amount of
documents this drastically increase performance (honestly that is a must
have in some situations, you can't just use CPU it is way too slow)
- **Dependencies:** no direct change to dependencies, but internally the
users will need to install `fastembed-gpu` instead of `fastembed`, I
made all the changes to the init function to properly let the user know
which dependency they should install depending on if they enabled `gpu`
or not
 
cf. fastembed docs about GPU for more details:
https://qdrant.github.io/fastembed/examples/FastEmbed_GPU/

I did not added test because it would require access to a GPU in the
testing environment
2025-02-06 08:04:19 -05:00
Dmitrii Rashchenko
0ceda557aa add o1 and o3-mini to pricing (#29628)
### PR Title:  
**community: add latest OpenAI models pricing**  

### Description:  
This PR updates the OpenAI model cost calculation mapping by adding the
latest OpenAI models, **o1 (non-preview)** and **o3-mini**, based on the
pricing listed on the [OpenAI pricing
page](https://platform.openai.com/docs/pricing).

### Changes:  
- Added pricing for `o1`, `o1-2024-12-17`, `o1-cached`, and
`o1-2024-12-17-cached` for input tokens.
- Added pricing for `o1-completion` and `o1-2024-12-17-completion` for
output tokens.
- Added pricing for `o3-mini`, `o3-mini-2025-01-31`, `o3-mini-cached`,
and `o3-mini-2025-01-31-cached` for input tokens.
- Added pricing for `o3-mini-completion` and
`o3-mini-2025-01-31-completion` for output tokens.

### Issue:  
N/A  

### Dependencies:  
None  

### Testing & Validation:  
- No functional changes outside of updating the cost mapping.  
- No tests were added or modified.
2025-02-06 08:02:20 -05:00
ZhangShenao
ac53977dbc [MistralAI] Improve MistralAIEmbeddings (#29242)
- Add static method decorator for method.
- Add expected exception for retry decorator

#29125
2025-02-05 21:31:54 -05:00
Andrew Wason
22aa5e07ed standard-tests: Fix ToolsIntegrationTests to correctly handle "content_and_artifact" tools (#29391)
**Description:**

The response from `tool.invoke()` is always a ToolMessage, with content
and artifact fields, not a tuple.
The tuple is converted to a ToolMessage here

b6ae7ca91d/libs/core/langchain_core/tools/base.py (L726)

**Issue:**

Currently `ToolsIntegrationTests` requires `invoke()` to return a tuple
and so standard tests fail for "content_and_artifact" tools. This fixes
that to check the returned ToolMessage.

This PR also adds a test that now passes.
2025-02-05 21:27:09 -05:00
Mohammad Anash
f849305a56 fixed Bug in PreFilter of AzureCosmosDBNoSqlVectorSearch (#29613)
Description: Fixes PreFilter value handling in Azure Cosmos DB NoSQL
vectorstore. The current implementation fails to handle numeric values
in filter conditions, causing an undefined value variable error. This PR
adds support for numeric, boolean, and NULL values while maintaining the
existing string and list handling.

Changes:
Added handling for numeric types (int/float)
Added boolean value support
Added NULL value handling
Added type validation for unsupported values
Fixed scope of value variable initialization

Issue: 
Fixes #29610

Implementation Notes:
No changes to public API
Backwards compatible
Maintains consistent behavior with existing MongoDB-style filtering
Preserves SQL injection prevention through proper value handling

---------

Co-authored-by: Chester Curme <chester.curme@gmail.com>
2025-02-06 02:20:26 +00:00
Chester Curme
a40db45a69 x 2025-02-05 21:14:31 -05:00
Philippe PRADOS
6ff0d5c807 community[minor]: 04 - Refactoring PDFMiner parser (#29526)
This is one part of a larger Pull Request (PR) that is too large to be
submitted all at once. This specific part focuses on updating the XXX
parser.

For more details, see [PR
28970](https://github.com/langchain-ai/langchain/pull/28970).

---------

Co-authored-by: Eugene Yurtsev <eyurtsev@gmail.com>
2025-02-05 21:08:27 -05:00
Chester Curme
13c67127b9 update api doc build workflow 2025-02-05 18:26:10 -05:00
Chester Curme
5db6442ad9 update api doc build workflow 2025-02-05 18:17:12 -05:00
Chester Curme
88dca23f8a increment anthropic version 2025-02-05 18:15:12 -05:00
Chester Curme
91fa2c3057 increment openai version 2025-02-05 18:13:52 -05:00
Chester Curme
b42e3c4556 increment text-splitters version 2025-02-05 18:12:16 -05:00
Chester Curme
540ec89e58 update api doc build workflow 2025-02-05 18:00:14 -05:00
Chester Curme
bdf045f9cd increment core version 2025-02-05 17:51:34 -05:00
ccurme
78f0568d43 infra: update docs for uv migration (#29620) 2025-02-05 16:53:59 -05:00
Chester Curme
895d20c12c x 2025-02-05 15:51:02 -05:00
Chester Curme
a34c0c3e65 Revert "temporarily disable ci checks"
This reverts commit ed46da39d1.
2025-02-05 15:47:37 -05:00
Chester Curme
899eae0403 x 2025-02-05 15:41:08 -05:00
Chester Curme
65e94a80d1 x 2025-02-05 15:01:39 -05:00
Chester Curme
42514d626d x 2025-02-05 14:47:08 -05:00
Chester Curme
dbccfc6da9 x 2025-02-05 14:33:52 -05:00
Chester Curme
6498021818 x 2025-02-05 14:28:12 -05:00
Yoav Levy
4460d20ba9 docs: Nimble provider doc fixes (#29597)
## Description

- Removed broken link for the API Reference
- Added `OPENAI_API_KEY` setter for the chains to properly run
- renamed one of our examples so it won't override the original
retriever and cause confusion due to it using a different mode of
retrieving
- Moved one of our simple examples to be the first example of our
retriever :)
2025-02-05 11:24:37 -08:00
Chester Curme
76e9546240 x 2025-02-05 14:22:47 -05:00
Chester Curme
1aed3e966d x 2025-02-05 14:17:07 -05:00
Chester Curme
a5106252bf x 2025-02-05 14:12:51 -05:00
Chester Curme
0f553cdcf0 x 2025-02-05 14:02:31 -05:00
Chester Curme
927b2526c3 a 2025-02-05 13:25:39 -05:00
Chester Curme
84146f365f x 2025-02-05 13:14:48 -05:00
Chester Curme
ff3db37670 x 2025-02-05 13:06:46 -05:00
Chester Curme
edf8b65dff x 2025-02-05 12:50:00 -05:00
Isaac Francisco
91ffd7caad core: allow passing message dicts into ChatPromptTemplate (#29363)
Co-authored-by: Erick Friis <erick@langchain.dev>
2025-02-05 09:45:52 -08:00
Chester Curme
36b15b9935 fix 2025-02-05 12:44:11 -05:00
Chester Curme
ed46da39d1 temporarily disable ci checks 2025-02-05 12:40:29 -05:00
Chester Curme
48909cf936 update scheduled test job 2025-02-05 12:31:36 -05:00
Chester Curme
e0d5fe6010 update docs workflows and scripts 2025-02-05 12:08:58 -05:00
Chester Curme
a2d6306339 monorepo 2025-02-05 11:52:12 -05:00
Chester Curme
ac64eccaa0 Revert "temporarily just run cli in ci"
This reverts commit c1e980ab67.
2025-02-05 11:43:41 -05:00
Chester Curme
42d980bcd8 x 2025-02-05 11:39:58 -05:00
Chester Curme
322ad54300 x 2025-02-05 11:37:14 -05:00
Chester Curme
cc055b2e76 x 2025-02-05 11:33:11 -05:00
Chester Curme
1f93811019 x 2025-02-05 11:23:38 -05:00
Chester Curme
9a140c58c8 x 2025-02-05 11:18:29 -05:00
Chester Curme
c1e980ab67 temporarily just run cli in ci 2025-02-05 11:18:23 -05:00
Chester Curme
7b7ae76a08 x 2025-02-05 11:00:01 -05:00
Chester Curme
76ebfe6bce uv doesn't automatically downgrade python version if it conflicts with pyproject.toml 2025-02-05 10:47:06 -05:00
Chester Curme
33e1e28dd7 standard-tests 2025-02-05 10:31:07 -05:00
Chester Curme
0397f46ab8 ollama 2025-02-05 10:28:22 -05:00