(no commit message)
This commit is contained in:
18
LICENSE
18
LICENSE
@@ -1,18 +0,0 @@
|
|||||||
MIT License
|
|
||||||
|
|
||||||
Copyright (c) 2025 fadeleke
|
|
||||||
|
|
||||||
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and
|
|
||||||
associated documentation files (the "Software"), to deal in the Software without restriction, including
|
|
||||||
without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
||||||
copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the
|
|
||||||
following conditions:
|
|
||||||
|
|
||||||
The above copyright notice and this permission notice shall be included in all copies or substantial
|
|
||||||
portions of the Software.
|
|
||||||
|
|
||||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT
|
|
||||||
LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO
|
|
||||||
EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
|
|
||||||
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
|
|
||||||
USE OR OTHER DEALINGS IN THE SOFTWARE.
|
|
||||||
0
__init__.py
Normal file
0
__init__.py
Normal file
9
agent.json
Normal file
9
agent.json
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
{
|
||||||
|
"metadata": {
|
||||||
|
"dependency_versions": {
|
||||||
|
"python": "3.11",
|
||||||
|
"dspy": "3.0.3",
|
||||||
|
"cloudpickle": "3.1"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
4
auto_classes.json
Normal file
4
auto_classes.json
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
{
|
||||||
|
"AutoConfig": "main.PromptToSignatureConfig",
|
||||||
|
"AutoAgent": "main.PromptToSignatureAgent"
|
||||||
|
}
|
||||||
4
config.json
Normal file
4
config.json
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
{
|
||||||
|
"lm": "gpt-4o",
|
||||||
|
"max_tokens": 1024
|
||||||
|
}
|
||||||
23
main.py
Normal file
23
main.py
Normal file
@@ -0,0 +1,23 @@
|
|||||||
|
from modaic import PrecompiledAgent, PrecompiledConfig
|
||||||
|
|
||||||
|
class PromptToSignatureConfig(PrecompiledConfig):
|
||||||
|
lm: str = "gpt-4o"
|
||||||
|
max_tokens: int = 1024
|
||||||
|
|
||||||
|
class PromptToSignatureAgent(PrecompiledAgent):
|
||||||
|
config: PromptToSignatureConfig
|
||||||
|
|
||||||
|
def __init__(self, config: PromptToSignatureConfig, **kwargs):
|
||||||
|
super().__init__(config, **kwargs)
|
||||||
|
|
||||||
|
def forward(self, prompt: str) -> str:
|
||||||
|
return "hello world"
|
||||||
|
|
||||||
|
|
||||||
|
agent = PromptToSignatureAgent(PromptToSignatureConfig())
|
||||||
|
|
||||||
|
def main():
|
||||||
|
agent.push_to_hub("fadeleke/prompt-to-signature", with_code=True)
|
||||||
|
|
||||||
|
if __name__ == "__main__":
|
||||||
|
main()
|
||||||
7
pyproject.toml
Normal file
7
pyproject.toml
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
[project]
|
||||||
|
name = "prompt-to-signature"
|
||||||
|
version = "0.1.0"
|
||||||
|
description = "Add your description here"
|
||||||
|
readme = "README.md"
|
||||||
|
requires-python = ">=3.11"
|
||||||
|
dependencies = ["dspy>=3.0.3", "modaic>=0.4.0", "rich>=14.2.0", "typer>=0.20.0"]
|
||||||
Reference in New Issue
Block a user