SDK de integração dos agentes da Paytime com o Agentes Hub
Project description
paytime-agent
SDK que liga um agente ao Agentes Hub. Heartbeat, execuções, parada cooperativa, log, alerta e artefato.
Instalação
Não está em índice público. Instale direto do repositório:
pip install git+https://github.com/paytime-ai/paytime-agent-sdk@v0.1.0
No requirements.txt do agente:
paytime-agent @ git+https://github.com/paytime-ai/paytime-agent-sdk@v0.1.0
Fixe a tag. Não use @main — um agente em produção não deve mudar de SDK
porque alguém deu merge.
Uso
from paytime_agent import Agent
agent = Agent.start()
agent.run_forever(processar, source=proximo_item)
Três variáveis de ambiente, geradas na tela de pareamento do Hub:
AGENT_ID, HUB_URL, HUB_TOKEN.
A especificação completa está em
docs/agent-contract.md
no repositório do Hub.
Duas garantias
Hub fora do ar não para agente. Toda falha de rede é engolida e registrada no
stdout. A única exceção que sobe para o código do agente é StopRequested.
SDK não bloqueia agente. Log, evento e execução vão para fila limitada, entregues por thread de fundo.
Testes
python smoke_test.py # sobe um Hub falso em 127.0.0.1 e exercita tudo
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 paytime_agent-0.1.1.tar.gz.
File metadata
- Download URL: paytime_agent-0.1.1.tar.gz
- Upload date:
- Size: 11.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/7.0.0 CPython/3.10.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
de01d5e692e1aacf04e30dd26038c4ca68c219c4a2326cdd2e1e115c74b8712e
|
|
| MD5 |
9e011fdfdd17719c9bb8936b8268e900
|
|
| BLAKE2b-256 |
75854af0ee5b103da63c8c0e03de164d6b0da861cac85f35ac638e08ab839c2f
|
File details
Details for the file paytime_agent-0.1.1-py3-none-any.whl.
File metadata
- Download URL: paytime_agent-0.1.1-py3-none-any.whl
- Upload date:
- Size: 12.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/7.0.0 CPython/3.10.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
af70a233b2400683b97213eb751479bf35f57c38e462765d2c4e745adc937c5f
|
|
| MD5 |
74291e789d435d45da7f596224b4767b
|
|
| BLAKE2b-256 |
11fbecd44959d81419a4f7f487fa5a90e63e4bfdf1fa8ac850107b591db9c8e0
|