{"id":31537665,"url":"https://github.com/snowheapllc/struktx","last_synced_at":"2025-10-04T08:08:56.298Z","repository":{"id":311453329,"uuid":"1039765345","full_name":"snowheapllc/StruktX","owner":"snowheapllc","description":"A configurable, typed AI framework with swappable LLM, classifier, handlers, and optional memory for NLP to Action flows","archived":false,"fork":false,"pushed_at":"2025-09-19T20:54:11.000Z","size":7103,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-09-29T18:13:34.345Z","etag":null,"topics":["ai","framework","langchain","llm","openai","python"],"latest_commit_sha":null,"homepage":"https://struktx.snowheap.ai","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/snowheapllc.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-08-17T23:55:21.000Z","updated_at":"2025-09-19T20:54:15.000Z","dependencies_parsed_at":"2025-08-24T19:44:49.205Z","dependency_job_id":"fdf40949-71fe-480a-a454-44f8b9a74e2f","html_url":"https://github.com/snowheapllc/StruktX","commit_stats":null,"previous_names":["snowheapllc/struktx"],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/snowheapllc/StruktX","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/snowheapllc%2FStruktX","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/snowheapllc%2FStruktX/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/snowheapllc%2FStruktX/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/snowheapllc%2FStruktX/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/snowheapllc","download_url":"https://codeload.github.com/snowheapllc/StruktX/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/snowheapllc%2FStruktX/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":278283509,"owners_count":25961311,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-04T02:00:05.491Z","response_time":63,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ai","framework","langchain","llm","openai","python"],"created_at":"2025-10-04T08:08:55.050Z","updated_at":"2025-10-04T08:08:56.292Z","avatar_url":"https://github.com/snowheapllc.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cdiv align=\"center\"\u003e\n  \u003cimg src=\"/docs/public/logo-blue.png\" alt=\"StruktX Logo\" width=\"120\" height=\"120\"\u003e\n  \u003cbr\u003e\n  \u003cimg src=\"/docs/public/nobg-both-white.png\" alt=\"StruktX\" width=\"200\"\u003e\n  \n  A configurable, typed AI framework with swappable LLM, classifier, handlers, and memory for Natural Language to Action apps\n  \n  [![Python 3.8+](https://img.shields.io/badge/python-3.8+-blue.svg)](https://www.python.org/downloads/)\n  [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)\n\u003c/div\u003e\n\n\n\n\n\n\n## Quick Install\n\n### Using uv (Recommended)\n```bash\n# Install with core dependencies only\nuv pip install struktx-ai\n\n# Install with LLM support (LangChain)\nuv pip install struktx-ai[llm]\n\n# Install with vector store support\nuv pip install struktx-ai[vector]\n\n# Install with all optional dependencies\nuv pip install struktx-ai[all]\n\n# Install for development\nuv pip install struktx-ai[dev]\n```\n\n### Using pip\n```bash\n# Install with core dependencies only\npip install struktx-ai\n\n# Install with LLM support (LangChain)\npip install struktx-ai[llm]\n\n# Install with vector store support\npip install struktx-ai[vector]\n\n# Install with all optional dependencies\npip install struktx-ai[all]\n```\n\n### Source\n```bash\n# Create virtual env\nuv venv\n\n# Activate environment\nsource .venv/bin/activate\n\n# Sync and install pyproject dependencies\nuv sync\n\n# Install finall Strukt package\nuv pip install struktx-ai[all]\n```\n\n## Quick Start with LangChain\n```python\nfrom strukt import create, StruktConfig, HandlersConfig, LLMClientConfig, ClassifierConfig\nfrom strukt.classifiers.llm_classifier import DefaultLLMClassifier\nfrom strukt.prompts import DEFAULT_CLASSIFIER_TEMPLATE\nfrom strukt.examples.time_handler import TimeHandler\n\nfrom langchain_openai import ChatOpenAI\nfrom strukt.langchain_helpers import LangChainLLMClient\n\n# Create LangChain LLM client\nlangchain_llm = ChatOpenAI(api_key=\"your-openai-api-key\")\nllm = LangChainLLMClient(langchain_llm)\n\napp = create(StruktConfig(\n    llm=LLMClientConfig(llm),\n    classifier=ClassifierConfig(\n        factory=DefaultLLMClassifier(\n            llm=llm,\n            prompt_template=DEFAULT_CLASSIFIER_TEMPLATE,\n            allowed_types=[\"time_service\", \"weather\", \"general\"],\n            max_parts=4,\n        )\n    ),\n    handlers=HandlersConfig(\n        registry={\"time_service\": TimeHandler(llm)},\n        default_route=\"general\",\n    ),\n))\n\napp.invoke(\"What is the time in Tokyo?\")\n```\n\n## What is StruktX?\n\nStruktX is a Python framework for building AI applications with focus on natural language -\u003e actions\n\n- **🔄 Swappable Components**: LLM clients, classifiers, handlers, and memory engines\n- **📝 Type Safety**: Full type hints and Pydantic models\n- **⚙️ Configurable**: Factory-based configuration system\n- **🔌 Extensible**: Easy to add custom components\n- **🧠 Memory Support**: Optional conversation memory\n- **🔧 Middleware**: Pre/post processing hooks\n\n## Features\n\n- **LLM Integration**: Support for any LLM via the `LLMClient` interface\n- **Query Classification**: Route requests to appropriate handlers\n- **Structured Outputs**: Pydantic model integration\n- **Memory Engines**: Conversation history and context\n- **Middleware System**: Pre/post processing hooks\n- **LangChain Helpers**: Easy integration with LangChain ecosystem\n\n## Requirements\n\n- Python 3.10+\n- Core: `pydantic\u003e=2.0.0`, `python-dotenv\u003e=1.0.0`\n- Optional: LangChain packages, vector stores, etc.\n\n## License\n\nMIT License - see [LICENSE](LICENSE) file for details.\n\n## Contributing\n\nContributions are welcome! Please report any issues, bugs, improvements, or features on GitHub.\n\n## Support\n\n- 📖 [Documentation](https://struktx.snowheap.ai/docs)\n- 🐛 [Issue Tracker](https://github.com/snowheapllc/StruktX/issues)\n- 💬 [Discussions](https://github.com/snowheapllc/StruktX/discussions)\n\n\u003cdiv align=\"right\"\u003e\n  \u003ca href=\"https://github.com/snowheapllc\"\u003e\n    \u003cimg src=\"/docs/public/snowheap.png\" alt=\"Snowheap LLC Logo\" width=\"100\"\u003e\n  \u003c/a\u003e\n\u003c/div\u003e\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsnowheapllc%2Fstruktx","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsnowheapllc%2Fstruktx","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsnowheapllc%2Fstruktx/lists"}