forked from IANTHEREAL/jarvis
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
improve readme and dockerfile (ngaut#63)
- Loading branch information
1 parent
c9515e0
commit 5a933ec
Showing
8 changed files
with
195 additions
and
64 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,70 @@ | ||
{ | ||
"cells": [ | ||
{ | ||
"cell_type": "code", | ||
"execution_count": 2, | ||
"metadata": {}, | ||
"outputs": [], | ||
"source": [ | ||
"import grpc\n", | ||
"import jarvis.server.jarvis_pb2 as jarvis_pb2\n", | ||
"import jarvis.server.jarvis_pb2_grpc as jarvis_pb2_grpc\n", | ||
"\n", | ||
"channel = grpc.insecure_channel(\"localhost:51155\")\n", | ||
"stub = jarvis_pb2_grpc.JarvisStub(channel)" | ||
] | ||
}, | ||
{ | ||
"cell_type": "code", | ||
"execution_count": null, | ||
"metadata": {}, | ||
"outputs": [], | ||
"source": [ | ||
"response=stub.Execute(\n", | ||
" jarvis_pb2.ExecuteRequest(\n", | ||
" task=(\n", | ||
" \"Collect the top three articles featured on Hacker News (https://news.ycombinator.com/), \"\n", | ||
" \"and produce a single professional reading summary that encompasses the content of all three articles, formatted in a user-friendly manner.\"\n", | ||
" )\n", | ||
" )\n", | ||
")\n", | ||
"response" | ||
] | ||
}, | ||
{ | ||
"cell_type": "code", | ||
"execution_count": null, | ||
"metadata": {}, | ||
"outputs": [], | ||
"source": [ | ||
"stub.SaveSkill(\n", | ||
" jarvis_pb2.SaveSkillRequest(\n", | ||
" executor_id=response.executor_id,\n", | ||
" skill_name=\"<customize skill name>\",\n", | ||
" )\n", | ||
")" | ||
] | ||
} | ||
], | ||
"metadata": { | ||
"kernelspec": { | ||
"display_name": "jarvis", | ||
"language": "python", | ||
"name": "python3" | ||
}, | ||
"language_info": { | ||
"codemirror_mode": { | ||
"name": "ipython", | ||
"version": 3 | ||
}, | ||
"file_extension": ".py", | ||
"mimetype": "text/x-python", | ||
"name": "python", | ||
"nbconvert_exporter": "python", | ||
"pygments_lexer": "ipython3", | ||
"version": "3.10.11" | ||
} | ||
}, | ||
"nbformat": 4, | ||
"nbformat_minor": 2 | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
# Overview | ||
|
||
Jarvis streamlines the process of task execution planning based on user-defined goals. Beyond that, it efficiently translates these tasks into JVM instructions, allowing seamless integration and execution. | ||
|
||
## How to Use Jarvis | ||
|
||
### Generating a Task Execution Plan | ||
|
||
For Direct Input Goals. Generate a plan for task execution directly from provided input goals: | ||
|
||
``` | ||
python -m jarvis --replan | ||
``` | ||
|
||
Using a Goal File. If you have predefined goals stored in a file, place this file in the 'workspace' directory. To generate a plan based on this file: | ||
|
||
``` | ||
python -m jarvis --replan --goalfile=<GOALFILE> | ||
``` | ||
|
||
### Translating Tasks to JVM Instructions | ||
|
||
Translate All Tasks. Convert all tasks in the execution plan into their corresponding JVM instructions: | ||
|
||
``` | ||
python -m jarvis | ||
``` | ||
|
||
Translate Specific Task. If you wish to only translate a task with a particular task number: | ||
|
||
``` | ||
python -m jarvis --compile=<task_num> | ||
``` | ||
|
||
## Executing JVM Instructions | ||
|
||
Execute JVM instructions based on the specified task. Here are a couple of examples: | ||
|
||
``` | ||
python -m jarvis --yaml=1.yaml | ||
python -m jarvis --yaml=2.yaml | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters