{"id":37070305,"url":"https://github.com/chigwell/thematic-structurizer","last_synced_at":"2026-01-14T08:12:09.256Z","repository":{"id":329725096,"uuid":"1120516527","full_name":"chigwell/thematic-structurizer","owner":"chigwell","description":"A new package would process user-provided text input related to historical or thematic content—such as summaries, descriptions, or analyses of topics like persuasion techniques from antiquity—and retu","archived":false,"fork":false,"pushed_at":"2025-12-21T11:44:12.000Z","size":4,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-12-23T03:17:30.116Z","etag":null,"topics":["consistency","content-curation","data-extraction","educational-tools","free-form-text","historical-content","llm","pattern-validation","predefined-format","regex-based-validation","reliability","research-assistants","retry-mechanisms","standardized-data-extraction","structured-output","text-analysis","text-description","text-processing","text-summarization","thematic-content"],"latest_commit_sha":null,"homepage":"https://pypi.org/project/thematic-structurizer/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/chigwell.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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-12-21T11:44:06.000Z","updated_at":"2025-12-21T11:44:26.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/chigwell/thematic-structurizer","commit_stats":null,"previous_names":["chigwell/thematic-structurizer"],"tags_count":null,"template":false,"template_full_name":null,"purl":"pkg:github/chigwell/thematic-structurizer","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chigwell%2Fthematic-structurizer","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chigwell%2Fthematic-structurizer/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chigwell%2Fthematic-structurizer/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chigwell%2Fthematic-structurizer/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/chigwell","download_url":"https://codeload.github.com/chigwell/thematic-structurizer/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chigwell%2Fthematic-structurizer/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28413616,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-14T05:26:33.345Z","status":"ssl_error","status_checked_at":"2026-01-14T05:21:57.251Z","response_time":107,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":["consistency","content-curation","data-extraction","educational-tools","free-form-text","historical-content","llm","pattern-validation","predefined-format","regex-based-validation","reliability","research-assistants","retry-mechanisms","standardized-data-extraction","structured-output","text-analysis","text-description","text-processing","text-summarization","thematic-content"],"created_at":"2026-01-14T08:12:08.728Z","updated_at":"2026-01-14T08:12:09.243Z","avatar_url":"https://github.com/chigwell.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# thematic-structurizer\n[![PyPI version](https://badge.fury.io/py/thematic-structurizer.svg)](https://badge.fury.io/py/thematic-structurizer)\n[![License: MIT](https://img.shields.io/badge/License-MIT-green.svg)](https://opensource.org/licenses/MIT)\n[![Downloads](https://static.pepy.tech/badge/thematic-structurizer)](https://pepy.tech/project/thematic-structurizer)\n[![LinkedIn](https://img.shields.io/badge/LinkedIn-blue)](https://www.linkedin.com/in/eugene-evstafev-716669181/)\n\n\nThematic Structurizer is a Python package designed to process user-provided text related to historical or thematic content—such as summaries, descriptions, or analyses of topics like persuasion techniques from antiquity—and extract structured, pattern-validated data. It leverages large language models (LLMs) to generate responses in a predefined format, ensuring consistency and reliability through regex validation and retry mechanisms.\n\n## Installation\n\nInstall the package via pip:\n\n```bash\npip install thematic_structurizer\n```\n\n## Usage\n\nHere's an example of how to use the package:\n\n```python\nfrom thematic_structurizer import thematic_structurizer\n\n# Example user input\nuser_input = \"Describe the persuasion techniques used by Cicero in ancient Rome.\"\n\n# Calling the function with default LLM (ChatLLM7)\nresponse = thematic_structurizer(user_input)\nprint(response)\n```\n\n## Custom LLM Support\n\nThe package uses `ChatLLM7` from `langchain_llm7` by default. You can provide your own language model instance to customize the behavior. Supported models include those from OpenAI, Anthropic, Google Generative AI, etc.\n\n### Example with a custom LLM:\n\n```python\nfrom langchain_openai import ChatOpenAI\nfrom thematic_structurizer import thematic_structurizer\n\nllm = ChatOpenAI()\nresponse = thematic_structurizer(user_input, llm=llm)\n```\n\n### Alternatively, using other providers:\n\n```python\nfrom langchain_anthropic import ChatAnthropic\nfrom thematic_structurizer import thematic_structurizer\n\nllm = ChatAnthropic()\nresponse = thematic_structurizer(user_input, llm=llm)\n```\n\n## API Key Management\n\nFor the default `ChatLLM7`, you can set your API key via environment variable:\n\n```bash\nexport LLM7_API_KEY='your_api_key'\n```\n\nor pass it directly:\n\n```python\nresponse = thematic_structurizer(user_input, api_key='your_api_key')\n```\n\nTo obtain a free API key, register at [https://token.llm7.io/](https://token.llm7.io/).\n\n## Function Details\n\n```python\ndef thematic_structurizer(\n    user_input: str,\n    api_key: Optional[str] = None,\n    llm: Optional[BaseChatModel] = None\n) -\u003e List[str]:\n```\n\n- `user_input`: The text to process, such as a description, summary, or analysis.\n- `llm`: An optional language model instance; defaults to `ChatLLM7`.\n- `api_key`: Optional string; API key for `ChatLLM7`.\n\nThis function processes the input, invokes the LLM, and returns a list of extracted data that match the predefined pattern validation.\n\n## License\n\nThis project is maintained by Eugene Evstafev. For issues or contributions, please visit [https://github.com/chigwell/thematic-structurizer](https://github.com/chigwell/thematic-structurizer).\n\n## Contact\n\n- Email: hi@eugene.plus\n- GitHub: [chigwell](https://github.com/chigwell)","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fchigwell%2Fthematic-structurizer","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fchigwell%2Fthematic-structurizer","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fchigwell%2Fthematic-structurizer/lists"}