Commit Graph

4478 Commits

Author SHA1 Message Date
Eugene Yurtsev
963e33804a x 2024-10-22 14:55:37 -04:00
Eugene Yurtsev
210f9e68c3 update 2024-10-22 14:30:37 -04:00
Eugene Yurtsev
2912559916 fix broken link 2024-10-22 14:29:21 -04:00
Eugene Yurtsev
b5f11d1967 update 2024-10-22 14:11:20 -04:00
Eugene Yurtsev
be5c73fa53 update 2024-10-22 13:49:23 -04:00
Eugene Yurtsev
7aa67885cf Update 2024-10-22 13:48:00 -04:00
Eugene Yurtsev
cb8e4d4a5f Merge branch 'concept_docs' of github.com:langchain-ai/langchain into concept_docs 2024-10-22 13:39:59 -04:00
Eugene Yurtsev
b68b89a230 Merge branch 'master' into concept_docs 2024-10-22 13:38:16 -04:00
Eugene Yurtsev
db544b1618
docs: update index page, update callbacks, add document loaders (#27528)
* update concepts index page
* update callbacks
* add document loaders
* update architecture to not use links in section headings
2024-10-22 13:06:16 -04:00
Eugene Yurtsev
95c813e4b8
concept docs more fixes (#27543)
Update architecture page
2024-10-22 11:13:40 -04:00
Eugene Yurtsev
acefe02334
docs: consolidate llms and chat models (#27525)
Consolidate the docs. After this, we'll need to potentially set up
redirect, and update links to existing llm pages.

Still not sure this is a good idea. May be better to rename the concept
page and redirect appropriately better, since we do still have string in
/ string out llm integrations
2024-10-22 10:40:04 -04:00
Eugene Yurtsev
e442e485fe
docs: update (#27520)
Collecting some feedback

---------

Co-authored-by: Lance Martin <lance@langchain.dev>
2024-10-21 21:37:51 -04:00
Eugene Yurtsev
606225e774
docs: streaming concept docs (#27516)
Streaming concept docs
2024-10-21 16:18:08 -04:00
Eugene Yurtsev
aa0b25cb2a
docs: fix some typos (#27519)
* Fix some typos
* Add some missing links
2024-10-21 16:00:31 -04:00
Eugene Yurtsev
13f7d2d58d
tools concept (#27482)
Add tools conceptual page
2024-10-21 15:34:21 -04:00
Erick Friis
c6d088bc15
docs: giscus component strict (#27515) 2024-10-21 11:36:51 -07:00
Lance Martin
8484c23c72
Address comments, minor cleanups (#27475) 2024-10-21 08:10:16 -07:00
Radi
689e8b7e66
docs: Update chatbot.ipynb (#27422)
- [ ] **PR title**: "docs: Typo fix"

Co-authored-by: Erick Friis <erick@langchain.dev>
2024-10-21 15:06:28 +00:00
venkatram-dev
2678cda83b
docs:tutorials:sql_qa.ipynb: fix typo (#27405)
Thank you for contributing to LangChain!

- [x] **PR title**: "package: description"

docs:docs:tutorials:sql_qa.ipynb: fix typo

- [x] **PR message**: ***Delete this entire checklist*** and replace
with
Fix typo in docs:docs:tutorials:sql_qa.ipynb


- [ ] **Add tests and docs**: If you're adding a new integration, please
include
1. a test for the integration, preferably unit tests that do not rely on
network access,
2. an example notebook showing its use. It lives in
`docs/docs/integrations` directory.


- [ ] **Lint and test**: Run `make format`, `make lint` and `make test`
from the root of the package(s) you've modified. See contribution
guidelines for more: https://python.langchain.com/docs/contributing/

Additional guidelines:
- Make sure optional dependencies are imported within a function.
- Please do not add dependencies to pyproject.toml files (even optional
ones) unless they are required for unit tests.
- Most PRs should not touch more than one package.
- Changes should be backwards compatible.
- If you are adding something to community, do not re-import it in
langchain.

If no one reviews your PR within a few days, please @-mention one of
baskaryan, efriis, eyurtsev, ccurme, vbarda, hwchase17.

---------

Co-authored-by: Erick Friis <erick@langchain.dev>
2024-10-21 15:01:23 +00:00
Erez Zohar
8f80dd28d9
docs: typo fix athena.ipynb and glue_catalog.ipynb (#27435)
**Description:** This PR fixes typos in 
```
docs/docs/integrations/document_loaders/athena.ipynb
docs/docs/integrations/document_loaders/glue_catalog.ipynb
```
2024-10-21 15:01:13 +00:00
Seungha Jeon
edfe35c2a8
docs: fix typo on friendli.ipynb (#27412)
This PR fixes typos in `chat/friendli.ipynb` and `llms/friendli.ipynb`
docs.
2024-10-21 14:58:49 +00:00
Connor Park
e62e390ca0
docs: update API Reference Link in /docs/how_to/vectorstore_retriever/ (#27477)
Description: updated docs
[here](https://python.langchain.com/docs/how_to/vectorstore_retriever/#:~:text=VectorStoreRetriever)
for creating VectorStoreRetrievers. The URL was missing a `.base`, and
now works as expected.

This was a fix for Issue #27196
2024-10-19 00:44:58 +00:00
Lance Martin
8033cae96a
First draft of concept pages (#27088)
Co-authored-by: Eugene Yurtsev <eyurtsev@gmail.com>
2024-10-18 12:52:52 -07:00
Eugene Yurtsev
127ac819fc
Docs: conceptual docs batch 1 (#27173)
Re-organizing some of the content involves runnables/lcel/streaming into
conceptual guides.

Conceptual guides added:
- [x] Runnables
- [x] LCEL
- [x] Chat Models
- [x] LLM
- [x] async
- [x] Messages
- [x] Chat History
- [x] Multimodality
- [x] Tokenization

Outstanding:
- [ ] Callbacks/Tracers
- [ ] Streaming
- [ ] Tool Creation
- [ ] Document Loading


Other conceptual guides are placeholders to make sure that no existing
links breaks.

Some high level re-organization:

* Introduce the Runnable interface prior to LCEL (since those are two
distinct concepts)
* Cross-link as much related content as possible (including how-to
guides)
2024-10-18 14:59:53 -04:00
Erick Friis
b468552859
docs: langgraph error code redirects (#27465) 2024-10-18 10:39:32 -07:00
Erick Friis
82242dfbb1
docs: openai audio docs (#27459) 2024-10-18 17:06:55 +00:00
Mateusz Szewczyk
97dc578d47
docs: Update custom name for IBM (#27437)
Thank you for contributing to LangChain!

PR: Update custom name for IBM in api_reference docs

Co-authored-by: Erick Friis <erick@langchain.dev>
2024-10-17 19:41:24 +00:00
Isaac Francisco
6e228c84a8
docs: update mongo table (#27434) 2024-10-17 18:29:29 +00:00
Erick Friis
2a27234a77
docs: fix error reference header (#27431) 2024-10-17 15:51:33 +00:00
Erick Friis
0ebddabf7d
docs, core: error messaging [wip] (#27397) 2024-10-17 03:39:36 +00:00
Erick Friis
a38e903360
docs: platforms -> providers (#27285) 2024-10-16 18:27:07 +00:00
ccurme
fdb7f951c8
monorepo: add script for updating notebook cassettes (#27399)
1. Move dependencies for running notebooks into monorepo poetry test
deps;
2. Add script to update cassettes for a single notebook;
3. Add cassettes for some how-to guides.

---

To update cassettes for a single notebook, run
`docs/scripts/update_cassettes.sh`. For example:
```
./docs/scripts/update_cassettes.sh docs/docs/how_to/binding.ipynb
```
Requires:
1. monorepo dev and test dependencies installed;
2. env vars required by notebook are set.

Note: How-to guides are not currently run in [scheduled
job](https://github.com/langchain-ai/langchain/actions/workflows/run_notebooks.yml).
Will add cassettes for more how-to guides in subsequent PRs before
adding them to scheduled job.
2024-10-16 13:46:49 -04:00
Artur Barseghyan
88d71f6986
docs: Cosmetic documentation fix. Update llm_chain.ipynb. (#27394)
ATM [LLM chain
docs](https://python.langchain.com/docs/tutorials/llm_chain/#server)
say:

```
# 3. Create parser
parser = StrOutputParser()

# 4. Create chain
chain = prompt_template | model | parser


# 4. App definition
app = FastAPI(
  title="LangChain Server",
  version="1.0",
  description="A simple API server using LangChain's Runnable interfaces",
)

# 5. Adding chain route
add_routes(
    app,
    chain,
    path="/chain",
)
```

I corrected it to:


```
# 3. Create parser
parser = StrOutputParser()

# 4. Create chain
chain = prompt_template | model | parser

# 5. App definition
app = FastAPI(
  title="LangChain Server",
  version="1.0",
  description="A simple API server using LangChain's Runnable interfaces",
)

# 6. Adding chain route
add_routes(
    app,
    chain,
    path="/chain",
)
```
2024-10-16 17:42:52 +00:00
sByteman
31e7664afd
community[minor]: add proxy support to RecursiveUrlLoader (#27364)
**Description**
This PR introduces the proxies parameter to the RecursiveUrlLoader
class, allowing the user to specify proxy servers for requests. This
update enables crawling through proxy servers, providing enhanced
flexibility for network configurations.
The key changes include:
  1.Added an optional proxies parameter to the constructor (__init__).
2.Updated the documentation to explain the proxies parameter usage with
an example.
3.Modified the _get_child_links_recursive method to pass the proxies
parameter to the requests.get function.



**Sample Usage**

```python
from bs4 import BeautifulSoup as Soup
from langchain_community.document_loaders.recursive_url_loader import RecursiveUrlLoader

proxies = {
    "http": "http://localhost:1080",
    "https": "http://localhost:1080",
}
url = "https://python.langchain.com/docs/concepts/#langchain-expression-language-lcel"
loader = RecursiveUrlLoader(
    url=url, max_depth=1, extractor=lambda x: Soup(x, "html.parser").text,proxies=proxies
)
docs = loader.load()
```

---------

Co-authored-by: root <root@thb>
2024-10-16 16:29:59 +00:00
Leonid Ganeline
3165415369
docs: integrations updates 21 (#27380)
Added missed provider pages. Added descriptions and links. Fixed
inconsistency in text formatting.

---------

Co-authored-by: Erick Friis <erickfriis@gmail.com>
Co-authored-by: Erick Friis <erick@langchain.dev>
2024-10-16 02:41:06 +00:00
Mateusz Szewczyk
591a3db4fb
docs: Update IBM ChatWatsonx documentation (#27358)
Thank you for contributing to LangChain!

We would like update IBM ChatWatsonx documentation in LangChain
documentation

Changes:
- Added support for `JSON mode`
- Added support for `Image Input`
- Added support for `Logprobs`

Chat Standard tests ->
https://github.com/langchain-ai/langchain-ibm/blob/main/libs/ibm/tests/integration_tests/test_chat_models_standard.py

Integration_tests job  ->
https://github.com/langchain-ai/langchain-ibm/actions/runs/11327509188

Co-authored-by: Erick Friis <erick@langchain.dev>
2024-10-16 02:27:56 +00:00
Leonid Ganeline
8e66822100
docs: integrations google update (#27218)
I've made several titles more compact hence a more compact menu.

Co-authored-by: Erick Friis <erick@langchain.dev>
2024-10-15 23:08:52 +00:00
Leonid Ganeline
fead4749b9
docs: integrations updates 20 (#27210)
Added missed provider pages. Added descriptions and links.

Co-authored-by: Erick Friis <erick@langchain.dev>
2024-10-15 16:38:12 +00:00
Qiu Qin
57fbc6bdf1
community: Update OCI data science integration (#27083)
This PR updates the integration with OCI data science model deployment
service.

- Update LLM to support streaming and async calls.
- Added chat model.
- Updated tests and docs.
- Updated `libs/community/scripts/check_pydantic.sh` since the use of
`@pre_init` is removed from existing integration.
- Updated `libs/community/extended_testing_deps.txt` as this integration
requires `langchain_openai`.

---------

Co-authored-by: MING KANG <ming.kang@oracle.com>
Co-authored-by: Dmitrii Cherkasov <dmitrii.cherkasov@oracle.com>
Co-authored-by: Erick Friis <erick@langchain.dev>
2024-10-15 08:32:54 -07:00
Rafael Miller
fc14f675f1
Community: Updated Firecrawl Document Loader to v1 (#26548)
This PR updates the Firecrawl Document Loader to use the recently
released V1 API of Firecrawl.

**Key Updates:**

**Firecrawl V1 Integration:** Updated the document loader to leverage
the new Firecrawl V1 API for improved performance, reliability, and
developer experience.

**Map Functionality Added:** Introduced the map mode for more flexible
document loading options.

These updates enhance the integration and provide access to the latest
features of Firecrawl.

---------

Co-authored-by: Erick Friis <erick@langchain.dev>
Co-authored-by: Harrison Chase <hw.chase.17@gmail.com>
2024-10-15 13:13:28 +00:00
YangZhaoo
de62d02102
docs: Maybe there is a missing closing bracket. (#27317)
Thank you for contributing to LangChain!

- [x] **PR title**: "package: description"
- Where "package" is whichever of langchain, community, core, etc. is
being modified. Use "docs: ..." for purely docs changes, "templates:
..." for template changes, "infra: ..." for CI changes.
  - Example: "community: add foobar LLM"


- [ ] **PR message**: ***Delete this entire checklist*** and replace
with
    - **Description:** a description of the change
    - **Issue:** the issue # it fixes, if applicable
    - **Dependencies:** any dependencies required for this change
- **Twitter handle:** if your PR gets announced, and you'd like a
mention, we'll gladly shout you out!


- [ ] **Add tests and docs**: If you're adding a new integration, please
include
1. a test for the integration, preferably unit tests that do not rely on
network access,
2. an example notebook showing its use. It lives in
`docs/docs/integrations` directory.


- [ ] **Lint and test**: Run `make format`, `make lint` and `make test`
from the root of the package(s) you've modified. See contribution
guidelines for more: https://python.langchain.com/docs/contributing/

Additional guidelines:
- Make sure optional dependencies are imported within a function.
- Please do not add dependencies to pyproject.toml files (even optional
ones) unless they are required for unit tests.
- Most PRs should not touch more than one package.
- Changes should be backwards compatible.
- If you are adding something to community, do not re-import it in
langchain.

If no one reviews your PR within a few days, please @-mention one of
baskaryan, efriis, eyurtsev, ccurme, vbarda, hwchase17.

---------

Co-authored-by: yangzhao <yzahha980122@gmail.com>
Co-authored-by: Chester Curme <chester.curme@gmail.com>
2024-10-14 12:46:56 -04:00
Erick Friis
2197958366
docs: add discussions with giscus (#27172) 2024-10-11 15:14:45 -07:00
Eugene Yurtsev
046f6a5544
concepts docs: archictecture individual page (#27290)
Update architecture page
2024-10-11 16:06:57 -04:00
Eugene Yurtsev
f8ce6210be
concept docs: add scaffold (#27277)
Starting to structure the scaffold for the concepts. Moving concept
content into their own pages.

TBD what we'll end up doing with the actual concepts page in terms of
visual layout.
2024-10-11 15:50:37 -04:00
Sir Qasim
2a1029c53c
Update chatbot.ipynb (#27243)
Async invocation:
remove : from at the end of line 
line 441 because there is not any structure block after it.

Thank you for contributing to LangChain!

- [ ] **PR title**: "package: description"
- Where "package" is whichever of langchain, community, core, etc. is
being modified. Use "docs: ..." for purely docs changes, "templates:
..." for template changes, "infra: ..." for CI changes.
  - Example: "community: add foobar LLM"


- [ ] **PR message**: ***Delete this entire checklist*** and replace
with
    - **Description:** a description of the change
    - **Issue:** the issue # it fixes, if applicable
    - **Dependencies:** any dependencies required for this change
- **Twitter handle:** if your PR gets announced, and you'd like a
mention, we'll gladly shout you out!


- [ ] **Add tests and docs**: If you're adding a new integration, please
include
1. a test for the integration, preferably unit tests that do not rely on
network access,
2. an example notebook showing its use. It lives in
`docs/docs/integrations` directory.


- [ ] **Lint and test**: Run `make format`, `make lint` and `make test`
from the root of the package(s) you've modified. See contribution
guidelines for more: https://python.langchain.com/docs/contributing/

Additional guidelines:
- Make sure optional dependencies are imported within a function.
- Please do not add dependencies to pyproject.toml files (even optional
ones) unless they are required for unit tests.
- Most PRs should not touch more than one package.
- Changes should be backwards compatible.
- If you are adding something to community, do not re-import it in
langchain.

If no one reviews your PR within a few days, please @-mention one of
baskaryan, efriis, eyurtsev, ccurme, vbarda, hwchase17.
2024-10-10 18:03:10 +00:00
Luke Jang
ff925d2ddc
docs: fixed broken API reference link for StructuredTool.from_function (#27181)
Fix broken API reference link for StructuredTool.from_function
2024-10-09 10:05:22 -04:00
Serena Ruan
a7c1ce2b3f
[community] Add timeout control and retry for UC tool execution (#26645)
Add timeout at client side for UCFunctionToolkit and add retry logic.
Users could specify environment variable
`UC_TOOL_CLIENT_EXECUTION_TIMEOUT` to increase the timeout value for
retrying to get the execution response if the status is pending. Default
timeout value is 120s.


- [ ] **Add tests and docs**: If you're adding a new integration, please
include
1. a test for the integration, preferably unit tests that do not rely on
network access,
2. an example notebook showing its use. It lives in
`docs/docs/integrations` directory.

Tested in Databricks:
<img width="1200" alt="image"
src="https://github.com/user-attachments/assets/54ab5dfc-5e57-4941-b7d9-bfe3f8ad3f62">



- [x] **Lint and test**: Run `make format`, `make lint` and `make test`
from the root of the package(s) you've modified. See contribution
guidelines for more: https://python.langchain.com/docs/contributing/

Additional guidelines:
- Make sure optional dependencies are imported within a function.
- Please do not add dependencies to pyproject.toml files (even optional
ones) unless they are required for unit tests.
- Most PRs should not touch more than one package.
- Changes should be backwards compatible.
- If you are adding something to community, do not re-import it in
langchain.

If no one reviews your PR within a few days, please @-mention one of
baskaryan, efriis, eyurtsev, ccurme, vbarda, hwchase17.

---------

Signed-off-by: serena-ruan <serena.rxy@gmail.com>
Co-authored-by: Erick Friis <erick@langchain.dev>
2024-10-09 06:31:48 +00:00
Jorge Piedrahita Ortiz
6c33124c72
docs: minor fix sambastudio chat model docs (#27212)
- **Description:**  minor fix sambastudio chat model docs

Co-authored-by: Erick Friis <erick@langchain.dev>
2024-10-08 23:34:29 +00:00
Mateusz Szewczyk
b298d0337e
docs: Update IBM ChatWatsonx documentation (#27189) 2024-10-08 21:10:18 +00:00
Leonid Ganeline
c3cb56a9e8
docs: integrations updates 18 (#27054)
Added missed provider pages. Added descriptions and links. Fixed
inconsistency in text formatting.

Co-authored-by: Erick Friis <erick@langchain.dev>
2024-10-08 19:05:07 +00:00