Compare commits
No commits in common. "0384397e28e22b6cbb2f12fc08cdf382ec8900ce" and "d1ad83501b8a086cc37bfd9785bfbbb35833caf0" have entirely different histories.
0384397e28
...
d1ad83501b
3
.gitmodules
vendored
3
.gitmodules
vendored
@ -1,6 +1,3 @@
|
|||||||
[submodule "make-llm-files"]
|
[submodule "make-llm-files"]
|
||||||
path = make-llm-files
|
path = make-llm-files
|
||||||
url = https://git.fredericofalcao.com/git/make-llm-files
|
url = https://git.fredericofalcao.com/git/make-llm-files
|
||||||
[submodule "process-telegram-updates"]
|
|
||||||
path = process-telegram-updates
|
|
||||||
url = https://git.fredericofalcao.com/git/make-telegram-updates
|
|
||||||
|
|||||||
@ -1 +0,0 @@
|
|||||||
Subproject commit 5c6601d7ec86c3e0baf4c1e6341830e8e66d84f7
|
|
||||||
15
src/Makefile
15
src/Makefile
@ -16,19 +16,6 @@ SRC_FILES=$(subst .score.txt,.notification.txt,$(SRC_SCORE_FILES))
|
|||||||
|
|
||||||
all: $(SRC_FILES)
|
all: $(SRC_FILES)
|
||||||
|
|
||||||
# 7. Processed received messages
|
|
||||||
process-telegram-updates: ../process-telegram-updates/process_message.php
|
|
||||||
cd ../process-telegram-updates && make fetch_updates
|
|
||||||
cd ../process-telegram-updates && make process_updates
|
|
||||||
|
|
||||||
../process-telegram-updates/process_message.php:
|
|
||||||
printf '%s\n' \
|
|
||||||
'<?php function process_message(array $$from,array $$chat,string $$date,string $$text) { '\
|
|
||||||
' if (substr($$text,0,7) == "/learn ") file_put_contents(__DIR__."/data/learnings.txt", substr($$text,7)."\n",FILE_APPEND); '\
|
|
||||||
' if (substr($$text,0,7) == "/memory") telegram_send_text($$chat["id"],file_get_contents(__DIR__."/data/learnings.txt"));'\
|
|
||||||
' }' > $@
|
|
||||||
|
|
||||||
|
|
||||||
# 6. Run the MAIL-ROUTE script to either notify the user of a new message, or ignore
|
# 6. Run the MAIL-ROUTE script to either notify the user of a new message, or ignore
|
||||||
%.notification.txt: %.score.txt %.header.txt %.summary.txt
|
%.notification.txt: %.score.txt %.header.txt %.summary.txt
|
||||||
TELEGRAM_BOT_TOKEN=$(TELEGRAM_BOT_TOKEN) TELEGRAM_CHAT_ID=$(TELEGRAM_CHAT_ID) ./mail-route $^ > $@
|
TELEGRAM_BOT_TOKEN=$(TELEGRAM_BOT_TOKEN) TELEGRAM_CHAT_ID=$(TELEGRAM_CHAT_ID) ./mail-route $^ > $@
|
||||||
@ -45,7 +32,6 @@ process-telegram-updates: ../process-telegram-updates/process_message.php
|
|||||||
%.summary.txt: %.email.txt
|
%.summary.txt: %.email.txt
|
||||||
cd ../make-llm-files && make clean
|
cd ../make-llm-files && make clean
|
||||||
echo "You are a machine executive assistant tasked with parsing emails. User will send the content of a received email, and you (agent) must send a one phrase (max 12 words) sentence as an executive summary of the email." > ../make-llm-files/01_root.sys
|
echo "You are a machine executive assistant tasked with parsing emails. User will send the content of a received email, and you (agent) must send a one phrase (max 12 words) sentence as an executive summary of the email." > ../make-llm-files/01_root.sys
|
||||||
cp ../process-telegram-updates/data/learnings.txt ../make-llm-files/02_learnings.sys
|
|
||||||
cp ../data/$< ../make-llm-files/user_message.txt
|
cp ../data/$< ../make-llm-files/user_message.txt
|
||||||
echo '{}' > ../make-llm-files/settings.json
|
echo '{}' > ../make-llm-files/settings.json
|
||||||
cd ../make-llm-files && make
|
cd ../make-llm-files && make
|
||||||
@ -57,7 +43,6 @@ process-telegram-updates: ../process-telegram-updates/process_message.php
|
|||||||
%.score.txt: %.email.txt
|
%.score.txt: %.email.txt
|
||||||
cd ../make-llm-files && make clean
|
cd ../make-llm-files && make clean
|
||||||
echo "You are a machine executive assistant tasked with parsing emails urgency/importance. User will send the content of a received email, and you (agent) must REPLY ONLY with a single score [0.00-1.00] where you assess how important/urgent the email is." > ../make-llm-files/01_root.sys
|
echo "You are a machine executive assistant tasked with parsing emails urgency/importance. User will send the content of a received email, and you (agent) must REPLY ONLY with a single score [0.00-1.00] where you assess how important/urgent the email is." > ../make-llm-files/01_root.sys
|
||||||
cp process-telegram-updates/data/learnings.txt ../make-llm-files/02_learnings.sys
|
|
||||||
cp ../data/$< ../make-llm-files/user_message.txt
|
cp ../data/$< ../make-llm-files/user_message.txt
|
||||||
echo '{"temperature": 0.8,"max_output_tokens":4}' > ../make-llm-files/settings.json
|
echo '{"temperature": 0.8,"max_output_tokens":4}' > ../make-llm-files/settings.json
|
||||||
cd ../make-llm-files && make
|
cd ../make-llm-files && make
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user