Metadata-Version: 2.1
Name: openai-toolgen
Version: 0.1.0
Summary: A library for generating tools for OpenAI projects
Home-page: https://github.com/visendi-labs/openai-toolgen
Author: Rasmus Nordström
Author-email: nordstrom.rasmus@gmail.com
Classifier: Programming Language :: Python :: 3
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Requires-Python: >=3.6
Description-Content-Type: text/markdown
License-File: LICENSE

A clean way to generate tools to be used with openai projects

```python
from typing import Annotated
from openai_toolgen import tool

@tool
def foo(
    arg1: Annotated[int, "Description about arg1"],
    arg2: Annotated[str, "Description about arg2"]
    ):
    """Description how to use foo"""
    ...

assert tool.export_all() == [
    {
        "type": "function",
        "name": "foo",
        "description": "Description how to use foo",
        "parameters": {
            "type": "object",
            "properties": {
                "arg1": { 
                    "type": "number",
                    "description": "Description about arg1"
                },
                "arg2": { 
                    "type": "string",
                    "description": "Description about arg2"
                }
            },
            "required": ["arg1", "arg2"]
        }
    }
]

```
