1bcoder 0.1.6__tar.gz → 0.1.8__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (101) hide show
  1. {1bcoder-0.1.6 → 1bcoder-0.1.8/1bcoder.egg-info}/PKG-INFO +109 -3
  2. {1bcoder-0.1.6 → 1bcoder-0.1.8}/1bcoder.egg-info/SOURCES.txt +10 -0
  3. 1bcoder-0.1.6/README.md → 1bcoder-0.1.8/PKG-INFO +1774 -1653
  4. 1bcoder-0.1.6/1bcoder.egg-info/PKG-INFO → 1bcoder-0.1.8/README.md +1759 -1668
  5. 1bcoder-0.1.8/_bcoder_data/agents/websearch.txt +28 -0
  6. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/aliases.txt +4 -2
  7. 1bcoder-0.1.8/_bcoder_data/doc/FLOWS.md +128 -0
  8. 1bcoder-0.1.8/_bcoder_data/doc/TRANSLATE.md +174 -0
  9. 1bcoder-0.1.8/_bcoder_data/flows/__pycache__/commit_message.cpython-311.pyc +0 -0
  10. 1bcoder-0.1.8/_bcoder_data/flows/commit_message.py +38 -0
  11. 1bcoder-0.1.8/_bcoder_data/flows/grounding.py +106 -0
  12. 1bcoder-0.1.8/_bcoder_data/flows/py_error_trace.py +87 -0
  13. 1bcoder-0.1.8/_bcoder_data/flows/simargl_files.py +66 -0
  14. 1bcoder-0.1.8/_bcoder_data/flows/webask.py +59 -0
  15. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/proc/md.py +2 -1
  16. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/profiles.txt +2 -0
  17. 1bcoder-0.1.8/_bcoder_data/scripts/Translate.txt +6 -0
  18. {1bcoder-0.1.6 → 1bcoder-0.1.8}/chat.py +719 -25
  19. {1bcoder-0.1.6 → 1bcoder-0.1.8}/pyproject.toml +32 -32
  20. {1bcoder-0.1.6 → 1bcoder-0.1.8}/1bcoder.egg-info/dependency_links.txt +0 -0
  21. {1bcoder-0.1.6 → 1bcoder-0.1.8}/1bcoder.egg-info/entry_points.txt +0 -0
  22. {1bcoder-0.1.6 → 1bcoder-0.1.8}/1bcoder.egg-info/requires.txt +0 -0
  23. {1bcoder-0.1.6 → 1bcoder-0.1.8}/1bcoder.egg-info/top_level.txt +0 -0
  24. {1bcoder-0.1.6 → 1bcoder-0.1.8}/LICENSE +0 -0
  25. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/__init__.py +0 -0
  26. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/agents/advance.txt +0 -0
  27. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/agents/ask.txt +0 -0
  28. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/agents/compact.txt +0 -0
  29. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/agents/concepts.txt +0 -0
  30. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/agents/fill.txt +0 -0
  31. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/agents/planning.txt +0 -0
  32. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/agents/scan.txt +0 -0
  33. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/agents/sqlite.txt +0 -0
  34. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/doc/MCP.md +0 -0
  35. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/doc/OLLAMA_SERVER_PARAM.md +0 -0
  36. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/doc/PARAM.md +0 -0
  37. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/doc/PROC.md +0 -0
  38. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/map.txt +0 -0
  39. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/proc/action-required.py +0 -0
  40. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/proc/add-save.py +0 -0
  41. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/proc/assist.py +0 -0
  42. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/proc/collect-files.py +0 -0
  43. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/proc/ctx_cut.py +0 -0
  44. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/proc/extract-code.py +0 -0
  45. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/proc/extract-files.py +0 -0
  46. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/proc/extract-list.py +0 -0
  47. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/proc/grounding-check.py +0 -0
  48. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/proc/mdx.py +0 -0
  49. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/proc/pattern-gate.py +0 -0
  50. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/proc/regexp-extract.py +0 -0
  51. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/proc/rude_words.py +0 -0
  52. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/proc/scan-save.py +0 -0
  53. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/proc/secret_check.py +0 -0
  54. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/proc/sql_readonly_guard.py +0 -0
  55. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/proc/tempctx-cut.py +0 -0
  56. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/prompts/analysis.txt +0 -0
  57. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/prompts/sumarise.txt +0 -0
  58. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/prompts.txt +0 -0
  59. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/scripts/AddFunction.txt +0 -0
  60. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/scripts/AskProject.txt +0 -0
  61. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/scripts/CheckRequirements.txt +0 -0
  62. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/scripts/DockerMySQL.txt +0 -0
  63. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/scripts/DockerNginx.txt +0 -0
  64. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/scripts/DockerPython.txt +0 -0
  65. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/scripts/DockerStack.txt +0 -0
  66. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/scripts/DuckDuckGoInstant.txt +0 -0
  67. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/scripts/EnvTemplate.txt +0 -0
  68. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/scripts/Explain.txt +0 -0
  69. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/scripts/ExploreProjectStructure.txt +0 -0
  70. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/scripts/GitIgnorePython.txt +0 -0
  71. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/scripts/MySQLDump.txt +0 -0
  72. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/scripts/NewScript.txt +0 -0
  73. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/scripts/PipFreeze.txt +0 -0
  74. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/scripts/PyPI.txt +0 -0
  75. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/scripts/Refactor.txt +0 -0
  76. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/scripts/RunAndFix.txt +0 -0
  77. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/scripts/SQLiteSchema.txt +0 -0
  78. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/scripts/WikiPage.txt +0 -0
  79. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/scripts/WikiSearch.txt +0 -0
  80. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/scripts/auto-bkup.txt +0 -0
  81. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/scripts/edit-control.txt +0 -0
  82. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/scripts/parallel_call.txt +0 -0
  83. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/scripts/personal/content/create-regular-content.txt +0 -0
  84. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/scripts/personal/content/plan.txt +0 -0
  85. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/scripts/personal/test/collect-data-from-test-environment.txt +0 -0
  86. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/scripts/plan.txt +0 -0
  87. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/scripts/remote/create-content-on-remote-server.txt +0 -0
  88. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/scripts/set_ctx.txt +0 -0
  89. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/scripts/simargl-cli_index_files.txt +0 -0
  90. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/scripts/simargl-cli_index_units.txt +0 -0
  91. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/scripts/simargl-cli_search.txt +0 -0
  92. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/scripts/team-map-worker.txt +0 -0
  93. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/scripts/team-search-worker.txt +0 -0
  94. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/scripts/team-summarize.txt +0 -0
  95. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/scripts/team-tree-worker.txt +0 -0
  96. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/scripts/test.txt +0 -0
  97. {1bcoder-0.1.6 → 1bcoder-0.1.8}/_bcoder_data/teams/code-analysis.yaml +0 -0
  98. {1bcoder-0.1.6 → 1bcoder-0.1.8}/map_index.py +0 -0
  99. {1bcoder-0.1.6 → 1bcoder-0.1.8}/map_query.py +0 -0
  100. {1bcoder-0.1.6 → 1bcoder-0.1.8}/setup.cfg +0 -0
  101. {1bcoder-0.1.6 → 1bcoder-0.1.8}/tests/test_utils.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: 1bcoder
3
- Version: 0.1.6
3
+ Version: 0.1.8
4
4
  Summary: AI coding assistant agent for 1B–7B local models (Ollama, LMStudio, llama.cpp). Terminal REPL with file editing, project map, agents, scripts, and parallel multi-model queries.
5
5
  Project-URL: Homepage, https://github.com/szholobetsky/1bcoder
6
6
  Project-URL: Repository, https://github.com/szholobetsky/1bcoder
@@ -328,6 +328,92 @@ Requires `prompt_toolkit` for full editing (arrow keys, Home/End, scroll). Falls
328
328
 
329
329
  ---
330
330
 
331
+ ### Translation (`/translate`)
332
+
333
+ Enables on-the-fly translation between your native language and English. Supports four modes:
334
+
335
+ | Mode | Backend | Model size | Quality | Private | Internet |
336
+ |---|---|---|---|---|---|
337
+ | `online` | Google Translate (deep-translator) | none | High | **No** | Required |
338
+ | `mini` | argostranslate | ~100 MB per language pair | Moderate | Yes | Not required |
339
+ | `offline` | NLLB-200 (ctranslate2) | ~2.4 GB download, ~600 MB after conversion | Good | Yes | Not required |
340
+ | `lm` | Local/remote Ollama model | depends on model | High | Yes | Not required |
341
+
342
+ > **Privacy warning:** `online` mode sends your text to Google servers. Do not use with confidential projects, proprietary code, or sensitive data. Use `mini`, `offline`, or `lm` mode instead.
343
+
344
+ **One-time setup:**
345
+
346
+ ```
347
+ # Fully offline, best local quality (downloads ~2.4 GB (converts to ~600 MB)):
348
+ > /translate setup lang:uk mode:offline
349
+
350
+ # Dedicated translation model via Ollama (no model switching overhead):
351
+ > /translate setup lang:uk mode:lm host:192.168.0.5:11434 model:translategemma:4b
352
+
353
+ # Or using a profile from profiles.txt:
354
+ > /translate setup lang:uk profile:lmtrans
355
+
356
+ # Minimal offline footprint (~100 MB per language pair):
357
+ > /translate setup lang:uk mode:mini
358
+
359
+ # Online (best quality, not for confidential work):
360
+ > /translate setup lang:uk mode:online
361
+
362
+ # Change only the host (all other settings stay):
363
+ > /translate setup host:openai://192.168.0.229:1234
364
+ ```
365
+
366
+ Config is saved globally to `~/.1bcoder/translate.json` and applied automatically on every future startup.
367
+
368
+ | Command | Description |
369
+ |---|---|
370
+ | `/translate setup [lang:uk] [mode:offline] [host:<url>] [model:<name>] [profile:<name>]` | Configure translation; all params optional, unset ones keep existing values |
371
+ | `/translate on` | Enable translation (uses saved language and mode) |
372
+ | `/translate off` | Disable translation |
373
+ | `/translate status` | Show lang, mode, lm_host, lm_model, enabled |
374
+ | `/translate last [mode:<m>] [lang:<code>]` | Retranslate last reply with optional overrides |
375
+
376
+ Common language codes: `uk` Ukrainian, `de` German, `fr` French, `pl` Polish, `es` Spanish, `zh` Chinese. Full list: `/doc translate`
377
+
378
+ How it works: user input is translated to English before the LLM call, and the reply is translated back to the native language after. The model always reasons in English; the user always reads and writes in their language.
379
+
380
+ To open the translated reply in the browser:
381
+
382
+ ```
383
+ /translate last
384
+ /proc run mdx translated
385
+ ```
386
+
387
+ Or use the built-in script:
388
+
389
+ ```
390
+ /script run Translate
391
+ ```
392
+
393
+ **`offline` mode — NLLB-200 (recommended for private use):**
394
+
395
+ Downloads the NLLB-200-distilled-600M model (~2.4 GB download, ~600 MB after int8 conversion) and runs fully in-process via ctranslate2. No Ollama model switching — the translation model lives in RAM alongside the main model, keeping full VRAM free for the LLM.
396
+
397
+ ```
398
+ /translate setup lang:uk mode:offline
399
+ ```
400
+
401
+ **`lm` mode — dedicated translation model on phone or remote device:**
402
+
403
+ Add a `lmtrans` profile in `~/.1bcoder/profiles.txt` pointing to the device running the translation model:
404
+
405
+ ```
406
+ lmtrans: 192.168.0.5:11434|translategemma:4b|ctx
407
+ ```
408
+
409
+ Then configure `/translate` to use it:
410
+
411
+ ```
412
+ /translate setup lang:uk mode:lm host:192.168.0.5:11434 model:translategemma:4b
413
+ ```
414
+
415
+ ---
416
+
331
417
  ### File operations
332
418
 
333
419
  | Command | Description |
@@ -1358,6 +1444,7 @@ Run a Python script against the last LLM reply. Useful for extracting filenames,
1358
1444
  ```
1359
1445
  /proc list # list available processors
1360
1446
  /proc run <name> # one-shot: run against last reply
1447
+ /proc run <name> translated # run against last translated reply (from /translate)
1361
1448
  /proc run <name> -f <file> # run against an external file instead of last reply
1362
1449
  /proc on grounding-check # persistent: run after every reply automatically
1363
1450
  /proc off # stop persistent processor
@@ -1389,8 +1476,8 @@ Built-in processors in `~/.1bcoder/proc/`:
1389
1476
  | `extract-list` | Convert first bullet/numbered list in reply to comma-separated line | one-shot |
1390
1477
  | `grounding-check` | Score identifiers against `map.txt`, warn if <50% | persistent / gate |
1391
1478
  | `collect-files` | Accumulate filenames to `.1bcoder/collected-files.txt` | persistent |
1392
- | `md` | Render last reply as formatted Markdown in terminal | one-shot |
1393
- | `mdx` | Render last reply as Markdown + LaTeX (KaTeX) + Mermaid diagrams in browser | one-shot |
1479
+ | `md` | Render last reply as formatted Markdown in terminal; add `translated` to use translated reply | one-shot |
1480
+ | `mdx` | Render last reply as Markdown + LaTeX (KaTeX) + Mermaid diagrams in browser; add `translated` to use translated reply | one-shot |
1394
1481
  | `ctx_cut` | Auto `/ctx cut` when context exceeds threshold (default 90%) | persistent |
1395
1482
  | `rude_words` | Alert if reply contains profanity (`ua` arg adds Ukrainian list) | persistent |
1396
1483
  | `secret_check` | Alert if reply contains sensitive names (google, anthropic…) | persistent |
@@ -1461,6 +1548,25 @@ Built-in team scripts in `~/.1bcoder/scripts/`:
1461
1548
 
1462
1549
  ---
1463
1550
 
1551
+ ### Flows (`/flow`)
1552
+
1553
+ Flows are deterministic Python pipelines — they run commands, loop over lists, and pass everything to the LLM in a **temporary context**. Only the final summary lands in your main conversation. Works reliably even with 1B models because the LLM only needs to read, not make tool decisions.
1554
+
1555
+ ```
1556
+ /flow list # list all available flows
1557
+ /flow webask what is asyncio -d 5 # web search → fetch top 5 pages → summarize
1558
+ /flow grounding fix MultilineTernary # extract codebase keywords → locate files → summarize
1559
+ /flow simargl_files add user auth # simargl retrieval → read matched files → explain
1560
+ /flow py_error_trace -f error.txt # parse traceback → read code at each location → explain
1561
+ /flow commit_message # git diff → generate commit message
1562
+ ```
1563
+
1564
+ Custom flows go in `~/.1bcoder/flows/<name>.py` (global) or `.1bcoder/flows/<name>.py` (project-local).
1565
+ Each flow is a Python file with a single `run(chat, args)` function.
1566
+ Full guide: `/doc flows`
1567
+
1568
+ ---
1569
+
1464
1570
  ### Session controls
1465
1571
 
1466
1572
  | Command | Description |
@@ -23,10 +23,19 @@ _bcoder_data/agents/fill.txt
23
23
  _bcoder_data/agents/planning.txt
24
24
  _bcoder_data/agents/scan.txt
25
25
  _bcoder_data/agents/sqlite.txt
26
+ _bcoder_data/agents/websearch.txt
27
+ _bcoder_data/doc/FLOWS.md
26
28
  _bcoder_data/doc/MCP.md
27
29
  _bcoder_data/doc/OLLAMA_SERVER_PARAM.md
28
30
  _bcoder_data/doc/PARAM.md
29
31
  _bcoder_data/doc/PROC.md
32
+ _bcoder_data/doc/TRANSLATE.md
33
+ _bcoder_data/flows/commit_message.py
34
+ _bcoder_data/flows/grounding.py
35
+ _bcoder_data/flows/py_error_trace.py
36
+ _bcoder_data/flows/simargl_files.py
37
+ _bcoder_data/flows/webask.py
38
+ _bcoder_data/flows/__pycache__/commit_message.cpython-311.pyc
30
39
  _bcoder_data/proc/action-required.py
31
40
  _bcoder_data/proc/add-save.py
32
41
  _bcoder_data/proc/assist.py
@@ -66,6 +75,7 @@ _bcoder_data/scripts/PyPI.txt
66
75
  _bcoder_data/scripts/Refactor.txt
67
76
  _bcoder_data/scripts/RunAndFix.txt
68
77
  _bcoder_data/scripts/SQLiteSchema.txt
78
+ _bcoder_data/scripts/Translate.txt
69
79
  _bcoder_data/scripts/WikiPage.txt
70
80
  _bcoder_data/scripts/WikiSearch.txt
71
81
  _bcoder_data/scripts/auto-bkup.txt