chore(style): apply black formatting

Co-authored-by: PR0M3TH3AN <[email protected]>
This commit is contained in:
google-labs-jules[bot]andPR0M3TH3AN committed 2026-02-26 19:10:25 +00:00
1 parent ece0dda09f
commit e40a245858
6 files changed
+108 -46

No files matched your search

+8 -8
View File
@@ -20,13 +20,9 @@ If `npx --no-install torch-lock init --help` prints initialization prompts, it m
---
### 3. [2026-02-25] (scheduler, daily, store, insight)
### 3. [2026-02-26] (scheduler, daily, retrieve)
### 1. [2026-02-25] (torch, scheduler, host-mode)
When running `npm run --prefix torch scheduler:daily`, the scheduler resolves config from `torch/torch-config.json` (cwd-scoped), not the repo-root `torch-config.json`.
### 2. [2026-02-25] (torch, scheduler, handoff)
A non-inter…
Memory retrieval seed for daily :: scheduler memory retrieval
---
@@ -40,6 +36,10 @@ A non-inter…
---
### 5. [2026-02-26] (scheduler, daily, retrieve)
### 5. [2026-02-25] (scheduler, daily, store, insight)
Memory retrieval seed for daily :: scheduler memory retrieval
### 1. [2026-02-25] (torch, scheduler, host-mode)
When running `npm run --prefix torch scheduler:daily`, the scheduler resolves config from `torch/torch-config.json` (cwd-scoped), not the repo-root `torch-config.json`.
### 2. [2026-02-25] (torch, scheduler, handoff)
A non-inter…
+29 -4
View File
@@ -68,7 +68,7 @@
"importance": 0.8,
"embedding_id": null,
"created_at": 1772047328158,
"last_seen": 1772075164390,
"last_seen": 1772132692957,
"source": "agent-output",
"ttl_days": null,
"merged_into": null,
@@ -119,7 +119,7 @@
"importance": 0.8,
"embedding_id": null,
"created_at": 1772049603683,
"last_seen": 1772075164390,
"last_seen": 1772132692957,
"source": "agent-output",
"ttl_days": null,
"merged_into": null,
@@ -170,7 +170,7 @@
"importance": 0.8,
"embedding_id": null,
"created_at": 1772050579374,
"last_seen": 1772075164390,
"last_seen": 1772132692957,
"source": "agent-output",
"ttl_days": null,
"merged_into": null,
@@ -272,7 +272,7 @@
"importance": 0.8,
"embedding_id": null,
"created_at": 1772073865813,
"last_seen": 1772075164390,
"last_seen": 1772132692957,
"source": "agent-output",
"ttl_days": null,
"merged_into": null,
@@ -380,5 +380,30 @@
"merged_into": null,
"pinned": false
}
],
[
"7c40af4d-c986-4bfd-9e29-84197600cb0d",
{
"schema_version": 1,
"id": "7c40af4d-c986-4bfd-9e29-84197600cb0d",
"agent_id": "scheduler-memory-daily",
"session_id": "session-mm3u1t5b",
"type": "batch_window",
"content": "Memory retrieval seed for daily :: scheduler memory retrieval",
"summary": "Memory retrieval seed for daily :: scheduler memory retrieval",
"tags": [
"scheduler",
"daily",
"retrieve"
],
"importance": 0.4,
"embedding_id": null,
"created_at": 1772132692943,
"last_seen": 1772132692957,
"source": "scheduler-retrieve",
"ttl_days": null,
"merged_into": null,
"pinned": false
}
]
]
@@ -0,0 +1,18 @@
{
"cadence": "daily",
"operation": "retrieve",
"runId": "session-mm3u1t5b",
"servicePath": "src/services/memory/index.js#getRelevantMemories",
"inputs": {
"agentId": "scheduler-memory-daily",
"promptPath": "",
"promptIntent": "scheduler memory retrieval",
"query": "scheduler | daily | agent | scheduler-memory-daily | intent | scheduler memory retrieval",
"events": 1
},
"outputs": {
"ingestedCount": 1,
"retrievedCount": 5
},
"status": "ok"
}
@@ -0,0 +1 @@
MEMORY_RETRIEVED
@@ -2,16 +2,23 @@ import os
import subprocess
import sys
def get_all_files(extensions=['.mjs', '.js']):
def get_all_files(extensions=[".mjs", ".js"]):
files = []
for root, dirs, filenames in os.walk('.'):
if 'node_modules' in root or '.git' in root or 'artifacts' in root or 'dist' in root:
for root, dirs, filenames in os.walk("."):
if (
"node_modules" in root
or ".git" in root
or "artifacts" in root
or "dist" in root
):
continue
for filename in filenames:
if any(filename.endswith(ext) for ext in extensions):
files.append(os.path.join(root, filename))
return files
def grep_file(filepath, all_files):
filename = os.path.basename(filepath)
name_no_ext = os.path.splitext(filename)[0]
@@ -31,16 +38,16 @@ def grep_file(filepath, all_files):
# Search for filename (e.g. "foo.mjs")
result_full = subprocess.run(
['git', 'grep', '-F', filename, '--', '.'],
capture_output=True, text=True
["git", "grep", "-F", filename, "--", "."], capture_output=True, text=True
)
# Search for name without extension (e.g. "foo") if it's not "index"
result_no_ext = None
if name_no_ext != 'index':
if name_no_ext != "index":
result_no_ext = subprocess.run(
['git', 'grep', '-F', name_no_ext, '--', '.'],
capture_output=True, text=True
["git", "grep", "-F", name_no_ext, "--", "."],
capture_output=True,
text=True,
)
output = result_full.stdout
@@ -52,7 +59,7 @@ def grep_file(filepath, all_files):
# Filter out self-references
count = 0
for line in lines:
if line.startswith(filepath.lstrip('./')):
if line.startswith(filepath.lstrip("./")):
continue
count += 1
@@ -61,6 +68,7 @@ def grep_file(filepath, all_files):
print(f"Error grepping {filepath}: {e}")
return 1 # Assume used on error
def main():
files = get_all_files()
candidates = []
@@ -68,11 +76,11 @@ def main():
# Known entry points or special files to exclude from "dead" list immediately
# These might not be imported but are used by scripts or configuration
exclusions = [
'./bin/torch-lock.mjs',
'./src/lib.mjs', # Main entry
'./src/constants.mjs', # Likely used
'./build.mjs',
'./eslint.config.mjs',
"./bin/torch-lock.mjs",
"./src/lib.mjs", # Main entry
"./src/constants.mjs", # Likely used
"./build.mjs",
"./eslint.config.mjs",
]
print(f"Scanning {len(files)} files...")
@@ -82,7 +90,7 @@ def main():
continue
# Skip test files
if '.test.' in f or '/test/' in f or '/tests/' in f:
if ".test." in f or "/test/" in f or "/tests/" in f:
continue
count = grep_file(f, files)
@@ -94,9 +102,10 @@ def main():
print("No candidates found.")
else:
print(f"Found {len(candidates)} candidates.")
with open('artifacts/candidates.txt', 'w') as f_out:
with open("artifacts/candidates.txt", "w") as f_out:
for c in candidates:
f_out.write(c + '\n')
f_out.write(c + "\n")
if __name__ == "__main__":
main()
+26 -17
View File
@@ -2,16 +2,23 @@ import os
import subprocess
import sys
def get_all_files(extensions=['.mjs', '.js']):
def get_all_files(extensions=[".mjs", ".js"]):
files = []
for root, dirs, filenames in os.walk('.'):
if 'node_modules' in root or '.git' in root or 'artifacts' in root or 'dist' in root:
for root, dirs, filenames in os.walk("."):
if (
"node_modules" in root
or ".git" in root
or "artifacts" in root
or "dist" in root
):
continue
for filename in filenames:
if any(filename.endswith(ext) for ext in extensions):
files.append(os.path.join(root, filename))
return files
def grep_file(filepath, all_files):
filename = os.path.basename(filepath)
name_no_ext = os.path.splitext(filename)[0]
@@ -31,16 +38,16 @@ def grep_file(filepath, all_files):
# Search for filename (e.g. "foo.mjs")
result_full = subprocess.run(
['git', 'grep', '-F', filename, '--', '.'],
capture_output=True, text=True
["git", "grep", "-F", filename, "--", "."], capture_output=True, text=True
)
# Search for name without extension (e.g. "foo") if it's not "index"
result_no_ext = None
if name_no_ext != 'index':
if name_no_ext != "index":
result_no_ext = subprocess.run(
['git', 'grep', '-F', name_no_ext, '--', '.'],
capture_output=True, text=True
["git", "grep", "-F", name_no_ext, "--", "."],
capture_output=True,
text=True,
)
output = result_full.stdout
@@ -52,7 +59,7 @@ def grep_file(filepath, all_files):
# Filter out self-references
count = 0
for line in lines:
if line.startswith(filepath.lstrip('./')):
if line.startswith(filepath.lstrip("./")):
continue
count += 1
@@ -61,6 +68,7 @@ def grep_file(filepath, all_files):
print(f"Error grepping {filepath}: {e}")
return 1 # Assume used on error
def main():
files = get_all_files()
candidates = []
@@ -68,11 +76,11 @@ def main():
# Known entry points or special files to exclude from "dead" list immediately
# These might not be imported but are used by scripts or configuration
exclusions = [
'./bin/torch-lock.mjs',
'./src/lib.mjs', # Main entry
'./src/constants.mjs', # Likely used
'./build.mjs',
'./eslint.config.mjs',
"./bin/torch-lock.mjs",
"./src/lib.mjs", # Main entry
"./src/constants.mjs", # Likely used
"./build.mjs",
"./eslint.config.mjs",
]
print(f"Scanning {len(files)} files...")
@@ -82,7 +90,7 @@ def main():
continue
# Skip test files
if '.test.' in f or '/test/' in f or '/tests/' in f:
if ".test." in f or "/test/" in f or "/tests/" in f:
continue
count = grep_file(f, files)
@@ -94,9 +102,10 @@ def main():
print("No candidates found.")
else:
print(f"Found {len(candidates)} candidates.")
with open('artifacts/candidates.txt', 'w') as f_out:
with open("artifacts/candidates.txt", "w") as f_out:
for c in candidates:
f_out.write(c + '\n')
f_out.write(c + "\n")
if __name__ == "__main__":
main()