LangChain integration library for AOps
Project description
aops
LangChain integration library for AOps — load and version-control your agent prompts from the AOps backend.
Installation
pip install aops
Quick Start
import aops
from aops.langchain import pull
from langchain_core.prompts import ChatPromptTemplate, HumanMessagePromptTemplate
from langchain_core.output_parsers import StrOutputParser
from langchain_openai import ChatOpenAI
aops.init(api_key="aops_...")
prompt = pull("my-agent/my-chain")
chain = (
ChatPromptTemplate.from_messages([
prompt,
HumanMessagePromptTemplate.from_template("{user_input}"),
])
| ChatOpenAI(model="gpt-4o-mini")
| StrOutputParser()
)
result = chain.invoke({"user_input": "Hello!"})
Requirements
- Python 3.12+
- AOps backend running (self-hosted)
- API key issued from the AOps UI: Agent detail page → API Keys → New API Key
Docs
- Configuration — API key,
aops.init(), environment variables - API Reference —
pull(),@chain_promptfunction & class decorators - Live Updates — polling, pattern selection guide
License
MIT
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file aops-0.3.0.tar.gz.
File metadata
- Download URL: aops-0.3.0.tar.gz
- Upload date:
- Size: 9.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
45dddf6560aa7e4c8237e627615b86b05d183fc0a4fc17c60b83e59b78708c09
|
|
| MD5 |
c4a33b71847b8ed9b9238b97f2b6a7cb
|
|
| BLAKE2b-256 |
0b315e3b0a21b051f7b0773b95dbeba27562e5c6e87de896f96f93a58be10006
|
Provenance
The following attestation bundles were made for aops-0.3.0.tar.gz:
Publisher:
release.yml on cow-coding/aops-python
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
aops-0.3.0.tar.gz -
Subject digest:
45dddf6560aa7e4c8237e627615b86b05d183fc0a4fc17c60b83e59b78708c09 - Sigstore transparency entry: 991495724
- Sigstore integration time:
-
Permalink:
cow-coding/aops-python@7cbf72b31acd9721e323c7c84e3a3d9fa9afcff7 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/cow-coding
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@7cbf72b31acd9721e323c7c84e3a3d9fa9afcff7 -
Trigger Event:
push
-
Statement type:
File details
Details for the file aops-0.3.0-py3-none-any.whl.
File metadata
- Download URL: aops-0.3.0-py3-none-any.whl
- Upload date:
- Size: 10.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6e12d2537c97026cbb499889bffc4e7e0fb19111d70cc23fffd9169a8a9ac716
|
|
| MD5 |
b38cf4408307f703f868df7db5554a3a
|
|
| BLAKE2b-256 |
c6acd2f4f6cf377fbc4994850c4f80bb9fe27e39f9f38299cb4bfb1bef222bf2
|
Provenance
The following attestation bundles were made for aops-0.3.0-py3-none-any.whl:
Publisher:
release.yml on cow-coding/aops-python
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
aops-0.3.0-py3-none-any.whl -
Subject digest:
6e12d2537c97026cbb499889bffc4e7e0fb19111d70cc23fffd9169a8a9ac716 - Sigstore transparency entry: 991495728
- Sigstore integration time:
-
Permalink:
cow-coding/aops-python@7cbf72b31acd9721e323c7c84e3a3d9fa9afcff7 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/cow-coding
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@7cbf72b31acd9721e323c7c84e3a3d9fa9afcff7 -
Trigger Event:
push
-
Statement type: