git: a7a39373d8aa - main - misc/py-langchain-core: New port: LangChain: Building applications with LLMs through composability

From: Yuri Victorovich <yuri_at_FreeBSD.org>
Date: Fri, 18 Jul 2025 20:53:01 UTC
The branch main has been updated by yuri:

URL: https://cgit.FreeBSD.org/ports/commit/?id=a7a39373d8aa450e7b12a0cc1481660200edc133

commit a7a39373d8aa450e7b12a0cc1481660200edc133
Author:     Yuri Victorovich <yuri@FreeBSD.org>
AuthorDate: 2025-07-18 20:48:22 +0000
Commit:     Yuri Victorovich <yuri@FreeBSD.org>
CommitDate: 2025-07-18 20:52:55 +0000

    misc/py-langchain-core: New port: LangChain: Building applications with LLMs through composability
---
 misc/Makefile                    |  1 +
 misc/py-langchain-core/Makefile  | 46 ++++++++++++++++++++++++++++++++++++++++
 misc/py-langchain-core/distinfo  |  3 +++
 misc/py-langchain-core/pkg-descr |  2 ++
 4 files changed, 52 insertions(+)

diff --git a/misc/Makefile b/misc/Makefile
index fac90a13732b..6f5349b39a06 100644
--- a/misc/Makefile
+++ b/misc/Makefile
@@ -456,6 +456,7 @@
     SUBDIR += py-ipyfastscape
     SUBDIR += py-jiwer
     SUBDIR += py-kartograph
+    SUBDIR += py-langchain-core
     SUBDIR += py-langsmith
     SUBDIR += py-laspy
     SUBDIR += py-lazrs
diff --git a/misc/py-langchain-core/Makefile b/misc/py-langchain-core/Makefile
new file mode 100644
index 000000000000..3b62d18fd4ae
--- /dev/null
+++ b/misc/py-langchain-core/Makefile
@@ -0,0 +1,46 @@
+PORTNAME=	langchain-core
+DISTVERSION=	0.3.69
+CATEGORIES=	misc python # machine-learning
+MASTER_SITES=	PYPI
+PKGNAMEPREFIX=	${PYTHON_PKGNAMEPREFIX}
+DISTNAME=	${PORTNAME:S/-/_/}-${PORTVERSION}
+
+MAINTAINER=	yuri@FreeBSD.org
+COMMENT=	LangChain: Building applications with LLMs through composability
+WWW=		https://python.langchain.com/docs/introduction/ \
+		https://github.com/langchain-ai/langchain
+
+LICENSE=	MIT
+
+BUILD_DEPENDS=	${PYTHON_PKGNAMEPREFIX}pdm-backend>0:devel/py-pdm-backend@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}wheel>0:devel/py-wheel@${PY_FLAVOR}
+RUN_DEPENDS=	${PYTHON_PKGNAMEPREFIX}jsonpatch>=1.33:devel/py-jsonpatch@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}langsmith>=0.3.45:misc/py-langsmith@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}packaging>=23.2:devel/py-packaging@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}pydantic2>=2.7.4:devel/py-pydantic2@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}pyyaml>=5.3:devel/py-pyyaml@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}tenacity>=8.4.0<10.0.0>=8.1.0:devel/py-tenacity@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}typing-extensions>=4.7:devel/py-typing-extensions@${PY_FLAVOR}
+TEST_DEPENDS=	${PYTHON_PKGNAMEPREFIX}blockbuster>=1.5.18:devel/py-blockbuster@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}freezegun>=1.2.2:devel/py-freezegun@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}grandalf>=0.8:math/py-grandalf@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}langchain-tests>0:misc/py-langchain-tests@${PY_FLAVOR} \
+		${PYNUMPY} \
+		${PYTHON_PKGNAMEPREFIX}pytest-asyncio>=0.21.1:devel/py-pytest-asyncio@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}pytest-benchmark>0:devel/py-pytest-benchmark@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}pytest-codspeed>0:devel/py-pytest-codspeed@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}pytest-mock>=3.10.0:devel/py-pytest-mock@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}pytest-socket>=0.7.0:devel/py-pytest-socket@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}pytest-watcher>0:devel/py-pytest-watcher@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}pytest-xdist>=3.6.1:devel/py-pytest-xdist@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}responses>=0.25.0:devel/py-responses@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}syrupy>=4.0.2:devel/py-syrupy@${PY_FLAVOR}
+
+USES=		python
+USE_PYTHON=	pep517 autoplist pytest
+
+NO_ARCH=	yes
+
+# tests fail with: INTERNALERROR> ValueError: no option named 'only_extended'
+
+.include <bsd.port.mk>
diff --git a/misc/py-langchain-core/distinfo b/misc/py-langchain-core/distinfo
new file mode 100644
index 000000000000..5a0903e1fb5a
--- /dev/null
+++ b/misc/py-langchain-core/distinfo
@@ -0,0 +1,3 @@
+TIMESTAMP = 1752809210
+SHA256 (langchain_core-0.3.69.tar.gz) = c132961117cc7f0227a4c58dd3e209674a6dd5b7e74abc61a0df93b0d736e283
+SIZE (langchain_core-0.3.69.tar.gz) = 563824
diff --git a/misc/py-langchain-core/pkg-descr b/misc/py-langchain-core/pkg-descr
new file mode 100644
index 000000000000..3ba3698d7f43
--- /dev/null
+++ b/misc/py-langchain-core/pkg-descr
@@ -0,0 +1,2 @@
+langchain-core is a core library of LangChain.
+LangChain is a framework for building LLM-powered applications.