python-agent-engine
Skill321 starsChanged 7 months agoMITView on GitHub
A production-ready Python AI Agent engine using LangChain. Supports ReAct pattern, tool calling, and thinking process tracking.
- Reads credentials
- Installs packages
In this repository32 other files it gives its agents.
- auto-page-syncSkill
- backlink-discoverySkill
- backlink-intelligenceSkill
- data-scraper-intentSkill
- favicon-icon-generatorSkill
- gemini-thinking-protocolSkill
- google-trends-to-pagesSkill
- html5-game-radarSkill
- itchio-new-game-huntSkill
- keyword-competition-analysisSkill
- multi-game-codes-hubSkill
- nextjs-seo-boosterSkill
- nextjs-seo-foundationsSkill
- null-axiom-twitterSkill
- plugin-architectSkill
- roblox-game-data-scraperSkill
- roblox-hit-evaluatorSkill
- roblox-homepage-ranking-auditorSkill
- roblox-site-architectSkill
- rpg-stat-catalystSkill
- seo-auditorSkill
- seo-autopilotSkill
- seo-backlink-submitterSkill
- seo-link-strategySkill
- signallayer-backlinks-clientSkill
- site-keyword-researchSkill
- x-demand-radarSkill
- youtube-content-genSkill
- youtube-game-keywordsSkill
- youtube-game-scoutSkill
- youtube-intelSkill
- youtube-transcribeSkill
The file
Files
Python Agent Engine
A plug-and-play AI Agent core for Python applications. It handles the complexity of LLM interaction, tool calling loops, and context management.
Features
- ReAct Loop: Automatically handles "Reasoning -> Tool Call -> Result -> Answer" process.
- Thinking Process: Returns structured "Thinking Steps" for UI visualization.
- Model Agnostic: Works with OpenAI, DeepSeek, or any OpenAI-compatible API.
Installation
- Copy
resources/agent_engine.pyto your project (e.g.,src/core/agent_engine.py). - Install dependencies:
pip install langchain-core langchain-openai python-dotenv - Set Environment Variables in your
.envfile:OPENAI_API_KEY=sk-... # Optional: OPENAI_BASE_URL=https://api.openai.com/v1
Usage Example
import asyncio
from langchain_core.tools import tool
from core.agent_engine import AgentEngine
# 1. Define Tools
@tool
def calculator(expression: str) -> str:
"""Calculates a math expression."""
return str(eval(expression))
# 2. Initialize Agent
agent = AgentEngine(
tools=[calculator],
system_prompt="You are a helpful math assistant.",
model_name="gpt-4o"
)
# 3. Chat
async def main():
response = await agent.chat("What is 123 * 456?")
print(f"Answer: {response.content}")
print("\nThinking Steps:")
for step in response.thinking_steps:
print(f"[{step.type}] {step.content}")
if __name__ == "__main__":
asyncio.run(main())Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

