Commit Graph

310 Commits

Author SHA1 Message Date
Nick Shirokov 24751a59de docs(epf-guide): clarify register column category limitation
Explain why stub database may lose DataPath bindings when forms
contain register record sets — source XML lacks dimension/resource/
attribute classification for register fields.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-07 21:06:28 +03:00
Nick Shirokov b824759a05 docs(skills): remove redundant description paragraphs from epf/erf skills
The intro paragraph on line 14 duplicated the frontmatter description
field. Per Anthropic best practices, the body should contain only
implementation details — the heading and frontmatter are sufficient.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-07 20:53:13 +03:00
Nick Shirokov fb23cbda56 docs(skills): remove cross-references between epf/erf skills
Drop "см. /erf-*" from epf-build/epf-dump and "Использует общий скрипт
из /epf-*" from erf-build/erf-dump to prevent the model from reading
duplicate skill files and wasting context.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-07 20:50:14 +03:00
Nick Shirokov 69c89d3d70 fix(meta-compile,stub-db-create): add missing GeneratedType categories
Add 6 missing categories to meta-compile (ps1+py):
- AccountingRegister: ExtDimensions
- ChartOfCharacteristicTypes: Characteristic
- ChartOfCalculationTypes: DisplacingCalculationTypesRow, BaseCalculationTypesRow, LeadingCalculationTypesRow
- BusinessProcess: RoutePointRef

Fix incorrect category name in stub-db-create (ps1+py):
- AccountingRegisterExtDimensionTypes/ExtDimensionTypes → AccountingRegisterExtDimensions/ExtDimensions

Add GeneratedType reference table to 1c-config-objects-spec.md (section 29).

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-07 20:24:31 +03:00
Nick Shirokov dee85e19d5 docs: update build-spec and epf-guide for auto-stub and dump requirements
- build-spec: replace outdated notes about empty base with auto-stub info
- build-spec: add dump notes about irreversible type loss in empty base
- epf-guide: add build/dump section explaining auto-stub and base requirement

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-07 19:40:25 +03:00
Nick Shirokov 87348ec73c docs(skills): add trigger descriptions, remove redundant sections, fix paths
- Add "Используй когда..." triggers to epf-build, epf-dump, erf-build, erf-dump
- Remove "Коды возврата" sections (trivial info Claude already knows)
- Remove Hierarchical tree diagrams from dump skills (Claude sees output directly)
- Fix Windows backslashes to forward slashes in examples

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-07 19:35:08 +03:00
Nick Shirokov dd81c85366 fix(stub-db-create): warn about guessed register column categories
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-07 19:13:31 +03:00
Nick Shirokov c6f499a099 feat(stub-db-create): scan Form.xml for register column names
Parse form attributes of RegisterRecordSet types and extract column
names from DataPath references. Generate matching Dimension/Attribute
stubs in register metadata so form field bindings survive the build.

Limitation: column categories (Dimension vs Resource vs Attribute)
cannot be determined from EPF sources alone — only names are preserved.

Also add /Out log for UpdateDBCfg errors in both PS1 and PY.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-07 19:10:10 +03:00
Nick Shirokov b5826a61c4 docs(epf-dump,erf-dump): mark database connection as required
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-07 18:35:44 +03:00
Nick Shirokov 3097811dde fix(epf-dump): require database connection, remove auto-create empty base
Dump in an empty database irreversibly loses reference types (CatalogRef,
DocumentRef, etc.) — they get converted to xs:string. Instead of silently
creating an empty temp database, the script now exits with an error
explaining that a real database is required.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-07 18:34:32 +03:00
Nick Shirokov f01f9d6ae8 feat(epf-build): auto-create stub database for EPF/ERF with reference types
Add stub-db-create script (.ps1/.py) that scans EPF XML sources for
reference types (CatalogRef, DocumentRef, EnumRef, etc.) and generates
a minimal 1C configuration with metadata stubs. Supports 14 metadata
types including registers, charts, defined types.

epf-build/erf-build: if no database specified, auto-create stub DB
with matching metadata, build EPF, then cleanup temp DB.

epf-dump/erf-dump: if no database specified, create empty DB with
warning that reference types will be converted to strings.

SKILL.md updated: prefer real database from .v8-project.json first,
fall back to auto-created stub only when unavailable.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-07 18:27:38 +03:00
Nick Shirokov 0a1f8888dc feat(form-compile,form-edit): add type synonym resolution for resilient DSL
Add Resolve-TypeStr/resolve_type_str to form-compile and form-edit (PS+PY)
that silently normalizes Russian type names (Строка→string, Число→decimal,
Булево→boolean, etc.), Number→decimal alias, and Russian reference prefixes
(СправочникСсылка→CatalogRef, etc.). Also accept + as composite type
separator alongside |. This makes form skills more forgiving when the model
uses meta-compile DSL conventions instead of form-specific ones.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-05 15:47:15 +03:00
Nick Shirokov 66eb0b19ec Merge dev-web: composite types, d5p1 namespace, IndentationError fixes
- meta-edit/meta-compile: composite types via + separator (PS+PY)
- d5p1 namespace for reference types instead of cfg:
- lxml post-processing fix for d5p1 in meta-edit PY
- meta-info/form-info: normalize d5p1 prefix in readers (PS+PY)
- Fix module-level IndentationError in 10 Python scripts
2026-03-05 14:01:18 +03:00
Nick Shirokov 872675652f fix: normalize d5p1 namespace in info scripts and fix Python IndentationErrors
- meta-info, form-info (PS+PY): recognize dNpN: prefix alongside cfg: in type parsing
- Fix module-level sys.stderr.reconfigure indentation in 9 Python scripts

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-05 12:08:07 +03:00
Nick Shirokov fde6d346d7 feat(meta-compile): support composite types and fix d5p1 namespace
- Add composite type support via + separator in Emit-TypeContent (PS/PY)
- Fix reference types: cfg: → d5p1: with local xmlns declaration
  in Emit-TypeContent, valueTypes loop, EventSubscription source
- Fix lxml stripping xmlns:d5p1 in meta-edit.py save_xml (post-process)
- Fix IndentationError in meta-compile.py and meta-validate.py
- Document composite type syntax in SKILL.md

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-05 12:00:09 +03:00
Nick Shirokov 4490aeb533 feat(meta-edit): support composite types via + separator
Build-TypeContentXml / build_type_content_xml now detect " + " in type
string, split into parts and recursively generate separate <v8:Type>
entries with qualifiers for each type. JSON DSL supports type as array.

Also fix reference types to use local xmlns:d5p1 declaration instead of
root-level cfg: prefix — prevents "Неизвестное имя типа" build errors.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-05 11:32:59 +03:00
Nick Shirokov 6958cc558b perf(web-test): detect .confirm notification for early exit in clickElement
Add .confirm CSS selector to the server-response waitForSelector in
clickElement. 1C web client shows notifications (Изменение/Проведение)
as .confirm elements after write/post operations. This allows early
exit instead of waiting the full 10s timeout. Записать: 14s → 2.6s.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-05 08:58:21 +03:00
Nick Shirokov 8a286d7191 perf(web-test): skip 10s server-wait for grid edit buttons in clickElement
When clicking toolbar buttons like "Добавить" that put focus into a grid
INPUT cell, skip the 10-second waitForSelector for modal/balloon since
no server round-trip is expected. Also replace fixed waits with polling
in fillTableRow add/row paths. Total: 121s → 62s on composite test suite.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-05 08:44:52 +03:00
Nick Shirokov a5fa730747 perf(web-test): replace fixed waits with polling in type-direct flow
Replace hardcoded waitForTimeout calls with polling loops that check
DOM state and exit early. Saves ~12s on composite-type test suite.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-05 08:33:02 +03:00
Nick Shirokov 53219cae6c fix(web-test): handle calculator/calendar popups and type inheritance in fillTableRow
When filling composite-type cells (String+Number+Date), the previous code
tried paste first and only fell back to type selection if paste was rejected.
This failed when rows inherited a type from previous rows — paste succeeded
but the value was silently converted to the wrong type.

Now when { value, type } is specified:
1. Always clear the cell first (Shift+F4) to reset inherited type
2. Open type dialog (F4) and select the requested type
3. Dismiss calculator/calendar popups with Escape
4. Re-enter edit mode if focus was lost, then paste the value

Tested with primitive types (Число/Строка/Дата) and reference types
(Физическое лицо via selection form). Regression-tested existing
composite-type flow in Операции.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-05 08:16:37 +03:00
Nick Shirokov b1187865ec feat(web-test): support composite-type fields in fillTableRow
Cells accepting multiple types (e.g. subconto on account 80.01) now
handled via { value, type } syntax. Paste rejection detected
automatically — F4 opens type dialog, picks type, then selects value
from the catalog form.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-04 22:18:27 +03:00
Nick Shirokov 22bf17ee00 feat(web-test): support per-field search in selectValue via object syntax
selectValue now accepts search as object { field: value } for per-field
disambiguation in selection forms. All fields use advanced search (Alt+F)
by specific column — more efficient than simple full-text search on large
tables, and navigates to exact row even in virtual grids.

Also fixes filterList modal cleanup: now checks specific dialog form
instead of generic modalSurface, preventing accidental closure of
parent modal forms (e.g. selection forms).

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-04 20:59:07 +03:00
Nick Shirokov 2e0dcb773b fix(web-test): detect ambiguous type matches in selectValue
When multiple types match the search term in the type selection dialog,
throw a descriptive error listing all matches instead of silently
picking the first one. This prevents the model from getting a misleading
"not found" error when the wrong type was selected.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-04 20:08:35 +03:00
Nick Shirokov c958f3f818 feat(web-test): support composite-type fields in selectValue
Add `{ type }` option to selectValue for fields that accept multiple
types (e.g. DocumentRef.*). When specified, selectValue navigates
through the type selection dialog via Ctrl+F search before opening
the value selection form. Auto-detects composite fields when type
is not specified and throws a helpful error message.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-04 19:51:08 +03:00
Nick Shirokov 684e97e518 docs(web-test): document icon-only section panel limitation
navigateSection() now gives a clear error message when the section
panel is in icon-only mode instead of a confusing "not found" error.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-04 15:09:16 +03:00
Nick Shirokov ce5651a5d7 feat(switch): add Windsurf, Kilo Code, Cline, Roo Code, Augment, Agent Skills platforms
Add 6 new platforms to switch.py (v1.0 → v1.1), total 13.
All follow the open Agent Skills standard (agentskills.io).
Update README with full platform table and agentskills.io reference.

Closes #4

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-03 16:56:02 +03:00
Nick Shirokov e706aca958 Merge branch 'dev-web' 2026-03-03 14:35:55 +03:00
Nick Shirokov 90b3d5d2e9 fix(web-test): require Message element for confirmation detection
Forms with multiple buttons but no form{N}_Message element were
falsely detected as confirmation dialogs. Real 1C confirmations
(Да/Нет) always have a Message element. Now skip forms without it.

Fixes false positives on small EPF forms with custom buttons.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-03 14:29:57 +03:00
Nick Shirokov 1b37bad331 docs(web-test): add openFile to testing guide
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-03 14:21:05 +03:00
Nick Shirokov 8b0664b18d fix(web-test): avoid confusing small EPF form with info dialog in openFile
Check form change before checkForErrors() to prevent misidentifying
a small EPF form (< 20 elements) as an informational modal dialog.
Only call checkForErrors() on suspiciously tiny new forms.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-03 14:19:24 +03:00
Nick Shirokov 2af73d25bf fix(web-test): handle follow-up info dialog after security confirmation in openFile
After clicking "Да" on the security confirmation, check for a second
informational modal ("please re-open the file"). If present, dismiss it
and retry the full Ctrl+O → filechooser cycle.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-03 14:17:33 +03:00
Nick Shirokov 449e2f667e feat(web-test): add openFile() for opening external processors (EPF/ERF)
Opens EPF/ERF files via Ctrl+O → 1C file dialog → native file picker.
Handles security confirmation dialog with up to 2 attempts for re-open.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-03 14:11:43 +03:00
Nick Shirokov e032143157 Merge branch 'dev-web': TTS narration, ElevenLabs provider, video recording guide, v8-project reference 2026-03-03 13:18:24 +03:00
Nick Shirokov 09fc3a7f43 docs(v8-project): note that file is in .gitignore due to secrets
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-03 13:16:45 +03:00
Nick Shirokov 01315839fb docs: add .v8-project.json reference guide
Consolidate project config documentation into a single guide covering all
fields (v8path, databases, webPath, ffmpegPath, tts, webUrl), with "who fills"
column and resolution algorithm. Replace duplicated format sections in
db-guide.md and web-guide.md with links to the new guide.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-03 13:14:08 +03:00
Nick Shirokov 6505fb1986 docs(web-test): update TTS provider recommendations with ElevenLabs findings
Recommend professional voices with educational/business profile (Olga, Artem,
Denis) for ElevenLabs Russian content. Note articulation issues with
multilingual model on Russian terminology (stress, vowel quality).

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-03 12:55:12 +03:00
Nick Shirokov 9e022c60f9 docs(web-test): add TTS provider recommendations to recording guide
Edge TTS recommended for Russian (better stress, intonation, semantic accents),
ElevenLabs for English/multilingual content (less robotic timbre).

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-03 12:19:23 +03:00
Nick Shirokov e23a235ffa fix(web-test): limit ElevenLabs TTS concurrency to 2 and improve error logging
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-03 12:10:01 +03:00
Nick Shirokov 5bccca2475 feat(web-test): add ElevenLabs TTS provider
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-03 11:15:36 +03:00
Nick Shirokov a8d8007846 docs(web-test): update stopRecording return type in recording.md
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-03 11:00:03 +03:00
Nick Shirokov 37d2a5ee15 docs(web-test): add video recording guide for users
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-03 10:58:27 +03:00
Nick Shirokov 050d42a457 fix(web-test): use video-time timestamps for precise TTS sync
Caption timestamps now use actual video timeline position (frame
counter) instead of wall-clock time, eliminating sync drift from
non-uniform frame duplication in CDP screencast recordings.

Also replace silence-file concatenation with adelay+amix for
sample-accurate TTS placement, and fix exec timeout for long
scenarios (fetch → http.request with 10min timeout).

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-03 10:13:32 +03:00
Nick Shirokov 5acb586bbf fix(web-test): fix audio-video sync drift in narration
Screencast frame duplication (Math.round) causes video to be ~5% longer
than wall-clock time. Caption timestamps are wall-clock based, so the
audio track drifted ahead by ~8s at the midpoint of a 5-minute video.

Fix:
- stopRecording() saves recordingDuration in captions.json
- addNarration() reads actual video duration via ffprobe and scales
  caption timestamps by videoDuration/recordingDuration ratio
- Phase 2 timeline now tracks actual cumulative position instead of
  computing gaps from previous caption data (prevents MP3 frame
  quantization drift)
- Also fixed findFfmpeg() → resolveFfmpeg() call in addNarration

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-03 00:45:30 +03:00
Nick Shirokov 7f6ea32533 refactor(web-test): add resolveEdgeTts() with fallback chain
Mirrors resolveFfmpeg() pattern: tries global/project-level import
first, then tools/tts/node_modules/, then throws error with install
instructions. Caches resolved module for subsequent calls.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-03 00:03:16 +03:00
Nick Shirokov e9b53505ac fix(web-test): move TTS to tools/tts/, use atempo instead of trimming
- node-edge-tts installed in tools/tts/ (alongside tools/ffmpeg/)
- Speed up TTS with ffmpeg atempo when it exceeds gap to next caption,
  instead of hard-cutting the audio

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-02 23:46:50 +03:00
Nick Shirokov 6ce36f7d9b fix(web-test): resolve node-edge-tts from tools/node_modules
Dynamic import needs file:// URL on Windows and explicit entry point
for ESM resolution. Package installed in tools/ alongside ffmpeg.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-02 23:29:56 +03:00
Nick Shirokov a13f16e49d feat(web-test): add TTS narration for video recordings
showCaption() collects captions with optional speech parameter,
stopRecording() saves .captions.json, addNarration() generates
TTS voiceover (Edge TTS or OpenAI) and merges audio with video.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-02 23:10:37 +03:00
Nick Shirokov 8f130f2e83 docs: update project description in README
Reflect the full development cycle the project now covers: from XML
artifacts to database management, web publishing, browser testing,
and video recording.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-02 20:34:42 +03:00
Nick Shirokov 26ea09e2ff fix(web-test): correct video color range for H.264 players
JPEG full range (0-255) was tagged as pc/full in H.264 output, but most
players (VLC, etc.) expect limited range (16-235). Convert JPEG→limited
with scale filter and tag as tv. Also switch preset ultrafast→fast for
5-6x smaller files on static screen content.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-02 20:05:32 +03:00
Nick Shirokov 98c416b5a7 fix(web-test): highlight commands before form elements
When the function panel is open over a form, highlight() was finding
buttons from the hidden form instead of visible commands on the panel.
Move command search (cmd_XXX_txt) to step 1 — before form-scoped
search — so visible panel commands always take priority. Form elements
searched at step 2 only if no command matched.

Highlight search order is now:
0. Open submenu/popup (elementFromPoint overlay)
1. Commands on function panel (visible cmd_ elements)
2. Form elements (buttons, fields, grid rows)
3. Sections (sidebar navigation)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-02 19:14:26 +03:00