mirror of
https://github.com/FoundationAgents/MetaGPT.git
synced 2026-06-11 15:15:18 +02:00
Modifying SPO's file path
This commit is contained in:
parent
1b933271e2
commit
3457026c55
12 changed files with 26 additions and 27 deletions
|
|
@ -49,8 +49,8 @@ ### 3. Implement the Optimizer 🔧
|
|||
Use `metagpt/ext/spo/optimize.py` to execute:
|
||||
|
||||
```python
|
||||
from metagpt.ext.spo.scripts.optimizer import Optimizer
|
||||
from metagpt.ext.spo.scripts.utils.llm_client import SPO_LLM
|
||||
from metagpt.ext.spo.components.optimizer import Optimizer
|
||||
from metagpt.ext.spo.utils.llm_client import SPO_LLM
|
||||
|
||||
if __name__ == "__main__":
|
||||
# Initialize LLM settings
|
||||
|
|
@ -62,12 +62,12 @@ ### 3. Implement the Optimizer 🔧
|
|||
|
||||
# Create and run optimizer
|
||||
optimizer = Optimizer(
|
||||
optimized_path="workspace", # Output directory
|
||||
initial_round=1, # Starting round
|
||||
max_rounds=10, # Maximum optimization rounds
|
||||
template="Poem.yaml", # Template file
|
||||
name="Poem", # Project name
|
||||
iteration=True, # Enable iteration mode
|
||||
optimized_path="workspace", # Output directory
|
||||
initial_round=1, # Starting round
|
||||
max_rounds=10, # Maximum optimization rounds
|
||||
template="Poem.yaml", # Template file
|
||||
name="Poem", # Project name
|
||||
iteration=True, # Enable iteration mode
|
||||
)
|
||||
|
||||
optimizer.optimize()
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
import argparse
|
||||
from metagpt.ext.spo.scripts.optimizer import Optimizer
|
||||
from metagpt.ext.spo.scripts.utils.llm_client import SPO_LLM
|
||||
from metagpt.ext.spo.components.optimizer import Optimizer
|
||||
from metagpt.ext.spo.utils.llm_client import SPO_LLM
|
||||
|
||||
|
||||
def parse_args():
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue