Files
OmniRoute/docs/i18n/ml/docs/compression/COMPRESSION_RULES_FORMAT.md
Diego Rodrigues de Sa e Souza 8feea123bb feat(docs): mirror every docs/ page in all 65 locales (#14106)
* feat(docs): mirror every docs/ page in all 65 locales

Extends the documentation mirrors from the 22-page core set (#13940) to
every Markdown page under docs/: 152 sources x 65 locales = 9,880 mirrors
(6,208 new), language bars rewritten for the full locale list, state
adopted so the blocking drift gate now covers all 152 pages.

run-translation.mjs: an oversized block made only of table rows or list
items (PROVIDER_REFERENCE.md 244-row table, FREE_TIERS.md 71-item list) is
cut at item boundaries and rejoined without a blank line — the single
16-40 KB request outlived the backend socket for verbose scripts. 48
older mirrors whose tables had lost rows were retranslated with --force.

* docs(i18n): refresh mirrors for the sources the base changed since the branch cut

Section-level retranslation of the 29 docs (and README.md) whose source
or mirrors moved on release/v3.8.51 during the run, then state adoption;
the drift gate is green again on the merged tree.
2026-09-18 13:16:46 -03:00

23 KiB

Compression Rules Format (മലയാളം)

🌐 Languages: 🇺🇸 English · 🇪🇹 am · 🇸🇦 ar · 🇦🇿 az · 🇧🇬 bg · 🇧🇩 bn · 🇨🇿 cs · 🇩🇰 da · 🇩🇪 de · 🇬🇷 el · 🇪🇸 es · 🇪🇪 et · 🇮🇷 fa · 🇫🇮 fi · 🇫🇷 fr · 🇮🇪 ga · 🇮🇳 gu · 🇳🇬 ha · 🇮🇱 he · 🇮🇳 hi · 🇭🇷 hr · 🇭🇺 hu · 🇦🇲 hy · 🇮🇩 id · 🇳🇬 ig · 🇮🇹 it · 🇯🇵 ja · 🇬🇪 ka · 🇰🇭 km · 🇮🇳 kn · 🇰🇷 ko · 🇱🇹 lt · 🇱🇻 lv · 🇮🇳 mr · 🇲🇾 ms · 🇲🇹 mt · 🇲🇲 my · 🇳🇵 ne · 🇳🇱 nl · 🇳🇴 no · 🇮🇳 or · 🇮🇳 pa · 🇵🇭 phi · 🇵🇱 pl · 🇵🇹 pt · 🇧🇷 pt-BR · 🇷🇴 ro · 🇷🇺 ru · 🇱🇰 si · 🇸🇰 sk · 🇸🇮 sl · 🇷🇸 sr · 🇸🇪 sv · 🇰🇪 sw · 🇮🇳 ta · 🇮🇳 te · 🇹🇭 th · 🇹🇷 tr · 🇺🇦 uk-UA · 🇵🇰 ur · 🇺🇿 uz · 🇻🇳 vi · 🇳🇬 yo · 🇨🇳 zh-CN · 🇹🇼 zh-TW


കംപ്രഷൻ നിയമങ്ങൾ റൺടൈമിൽ ലോഡ് ചെയ്യുന്ന JSON ഫയലുകളാണ്. എൻജിൻ കോഡ് മാറ്റാതെ തന്നെ പുതിയ ഭാഷാ പാക്കുകളും RTK കമാൻഡ് ഫിൽട്ടറുകളും അവലോകനം ചെയ്യാൻ കഴിയുന്നതിനായി അവ മനഃപൂർവം ഡാറ്റ മാത്രമായി പരിമിതപ്പെടുത്തിയിരിക്കുന്നു.

ആധികാരിക സ്കീമ (സത്യത്തിന്റെ ഉറവിടം): open-sse/services/compression/rules/_schema.json (JSON Schema draft 2020-12). താഴെയുള്ള ഉദാഹരണങ്ങൾ വിശദീകരണത്തിനുള്ളവയാണ് — സംശയമുണ്ടെങ്കിൽ, നിങ്ങളുടെ പാക്ക് _schema.json-ന് എതിരായി സാധൂകരിക്കുക.

Caveman നിയമ പാക്കുകൾ

Caveman നിയമ പാക്കുകൾ ഇനിപ്പറയുന്ന പാതയ്ക്ക് കീഴിലാണ്:

open-sse/services/compression/rules/<language>/<pack>.json

സംരക്ഷിത മേഖലകൾ വേർതിരിച്ചശേഷം സാധാരണ ഗദ്യത്തിൽ പ്രയോഗിക്കുന്ന പകരംവെക്കലുകൾ ഓരോ പാക്കിലും അടങ്ങിയിരിക്കുന്നു.

{
  "language": "en",
  "category": "filler",
  "rules": [
    {
      "name": "question_to_directive",
      "pattern": "\\b(?:Can you explain why|Could you show me how)\\b\\s*",
      "replacement": "Explain why ",
      "replacementMap": {
        "can you explain why": "Explain why ",
        "could you show me how": "Show how "
      },
      "flags": "gi",
      "context": "all",
      "category": "context",
      "minIntensity": "lite",
      "description": "Convert verbose questions into direct requests."
    }
  ]
}

Caveman ഫീൽഡുകൾ

ഫീൽഡ് നിർബന്ധം വിവരണം
language അതെ en, pt-BR, es എന്നിവ പോലുള്ള BCP-47-സദൃശ ഭാഷാ കീ
category അതെ പാക്ക് വിഭാഗത്തിന്റെ ഫയൽനാമം/വിഭാഗം, ഉദാഹരണത്തിന് filler അല്ലെങ്കിൽ dedup
rules അതെ regex പകരംവെക്കൽ നിയമങ്ങളുടെ അറേ
rules[].name അതെ സ്ഥിരതയുള്ള നിയമനാമം
rules[].pattern അതെ JavaScript regex സോഴ്സ്
rules[].flags അല്ല JavaScript regex ഫ്ലാഗുകൾ; ഡിഫോൾട്ട് gi
rules[].replacement അല്ല പകരംവെക്കൽ സ്ട്രിംഗ്, അല്ലെങ്കിൽ replacementMap-ൽ പൊരുത്തം ലഭിക്കാത്തപ്പോഴുള്ള ഫാൾബാക്ക്
rules[].replacementMap അല്ല നോർമലൈസ് ചെയ്ത പൊരുത്തപ്പെട്ട ടെക്സ്റ്റ് കീകളാക്കിയ, പൊരുത്ത-നിർദ്ദിഷ്ട പകരംവെക്കലുകൾ
rules[].context അല്ല all, user, assistant, അല്ലെങ്കിൽ system; ഡിഫോൾട്ട് all
rules[].category അല്ല filler, context, structural, dedup, terse, അല്ലെങ്കിൽ ultra
rules[].minIntensity അല്ല lite, full, അല്ലെങ്കിൽ ultra; ഡിഫോൾട്ട് lite
rules[].description അല്ല മനുഷ്യർക്ക് വായിച്ചുമനസ്സിലാക്കാവുന്ന നിയമസംഗ്രഹം

കേസ്-സെൻസിറ്റീവ് പൊരുത്തപ്പെടുത്തൽ പ്രധാനമാകുമ്പോൾ flags ഉപയോഗിക്കുക; ഉദാഹരണത്തിന്, the OpenAI API നീക്കം ചെയ്യാതെ ചെറിയക്ഷരത്തിലുള്ള ഗദ്യത്തിന് മുമ്പുള്ള ആർട്ടിക്കിൾ നീക്കം ചെയ്യാൻ. ഒരു regex-ന് വ്യത്യസ്ത ഔട്ട്പുട്ടുകൾ ആവശ്യമായ ഒന്നിലധികം ബദൽ രൂപങ്ങൾ ഉള്ളപ്പോൾ replacementMap ഉപയോഗിക്കുക; കൂടുതൽ സമ്പന്നമായ ബിൽറ്റ്-ഇൻ TypeScript പകരംവെക്കൽ ഫങ്ഷനുകളുടെ സ്വഭാവം നിലനിർത്തിക്കൊണ്ട് JSON നിയമ പാക്കുകളെ ഡാറ്റ മാത്രമായി പരിമിതപ്പെടുത്താൻ ഇത് സഹായിക്കുന്നു.

RTK ഫിൽട്ടർ പാക്കുകൾ

RTK ഫിൽട്ടറുകൾ ഇവിടെ സ്ഥിതിചെയ്യുന്നു:

open-sse/services/compression/engines/rtk/filters/<filter>.json

ഒരു കമാൻഡ്-ഔട്ട്പുട്ട് കുടുംബത്തെ എങ്ങനെ തിരിച്ചറിയണമെന്നും കംപ്രസ് ചെയ്യണമെന്നും ഓരോ ഫിൽട്ടറും വിവരിക്കുന്നു.

{
  "id": "test-vitest",
  "label": "Vitest output",
  "category": "test",
  "priority": 92,
  "match": {
    "outputTypes": ["test-vitest"],
    "commands": ["vitest", "npm test", "npm run test"],
    "patterns": ["\\bFAIL\\b", "\\bPASS\\b", "\\bTest Files\\b"]
  },
  "rules": {
    "stripAnsi": true,
    "replace": [{ "pattern": "\\s+\\[[0-9]+ms\\]", "replacement": "" }],
    "matchOutput": [
      {
        "pattern": "All tests passed",
        "message": "vitest: ok",
        "unless": "FAIL|Error:"
      }
    ],
    "includePatterns": ["FAIL", "Error:", "Test Files", "Tests"],
    "dropPatterns": ["^\\s*$", "Duration\\s+\\d+"],
    "collapsePatterns": ["^\\s+at "],
    "deduplicate": true,
    "truncateLineAt": 240,
    "maxLines": 160,
    "headLines": 24,
    "tailLines": 40,
    "onEmpty": "vitest: ok",
    "filterStderr": false
  },
  "preserve": {
    "errorPatterns": ["FAIL", "Error:", "AssertionError"],
    "summaryPatterns": ["Test Files", "Tests", "Snapshots"]
  },
  "tests": [
    {
      "name": "keeps failing tests",
      "command": "vitest",
      "input": "FAIL test/a.test.ts\\nError: boom\\nTest Files 1 failed",
      "expected": "FAIL test/a.test.ts\\nError: boom\\nTest Files 1 failed"
    }
  ]
}

RTK ഫീൽഡുകൾ

ഫീൽഡ് നിർബന്ധമാണോ വിവരണം
id അതെ മാറ്റമില്ലാത്ത ഫിൽട്ടർ ഐഡി
label അതെ ഡാഷ്ബോർഡിൽ വായിക്കാവുന്ന പേര്
category അതെ ഫിൽട്ടർ കുടുംബം: git, test, build, shell, docker, package, infra, cloud, generic
priority അല്ല ഒന്നിലധികം ഫിൽട്ടറുകൾ പൊരുത്തപ്പെടുമ്പോൾ ഉയർന്ന മുൻഗണനയുള്ളത് തിരഞ്ഞെടുക്കപ്പെടും
match.outputTypes അല്ല ഈ ഫിൽട്ടർ തിരഞ്ഞെടുക്കുന്ന ഡിറ്റക്ടർ ഔട്ട്പുട്ട് ഐഡികൾ
match.commands അല്ല ഈ ഫിൽട്ടർ തിരഞ്ഞെടുക്കുന്ന കമാൻഡ് ടോക്കണുകൾ
match.patterns അല്ല ഔട്ട്പുട്ട് ടെക്സ്റ്റിൽനിന്ന് ഈ ഫിൽട്ടർ തിരഞ്ഞെടുക്കുന്ന റെഗുലർ എക്സ്പ്രഷൻ പാറ്റേണുകൾ
rules.stripAnsi അല്ല റെഗുലർ എക്സ്പ്രഷൻ ഘട്ടങ്ങൾക്കുമുമ്പ് ANSI എസ്കേപ്പ് സീക്വൻസുകൾ നീക്കംചെയ്യുക
rules.replace അല്ല വരി തിരിച്ച് ക്രമാനുസൃതമായി പ്രയോഗിക്കുന്ന റെഗുലർ എക്സ്പ്രഷൻ പകരംവയ്ക്കലുകൾ
rules.matchOutput അല്ല ഐച്ഛികമായ unless ഗാർഡോടുകൂടിയ ഷോർട്ട്-സർക്യൂട്ട് ഔട്ട്പുട്ട് നിയമങ്ങൾ
rules.includePatterns അല്ല നിലനിർത്തുന്നതിന് മുൻഗണന നൽകേണ്ട വരികൾ
rules.dropPatterns അല്ല അനാവശ്യ ഉള്ളടക്കമായി കണക്കാക്കി നീക്കംചെയ്യേണ്ട വരികൾ
rules.collapsePatterns അല്ല ചുരുക്കാവുന്ന, ആവർത്തിച്ച് പൊരുത്തപ്പെടുന്ന വരികൾ
rules.deduplicate അല്ല ആവർത്തിക്കുന്ന നോർമലൈസ് ചെയ്ത വരികൾ ചുരുക്കുക
rules.truncateLineAt അല്ല ഓരോ വരിയിലുമുള്ള Unicode-സുരക്ഷിതമായ പ്രതീകപരിധി
rules.maxLines അല്ല അവസാനഭാഗം സംരക്ഷിക്കുന്നതിന് മുമ്പ് നിലനിർത്താവുന്ന പരമാവധി വരികൾ
rules.headLines അല്ല ചുരുക്കുമ്പോൾ നിലനിർത്തുന്ന ആദ്യഭാഗത്തെ വരികൾ
rules.tailLines അല്ല സമീപകാല സന്ദർഭത്തിനായി നിലനിർത്തുന്ന അവസാനഭാഗത്തെ വരികൾ
rules.onEmpty അല്ല ഫിൽട്ടറിംഗ് എല്ലാ ഉള്ളടക്കവും നീക്കംചെയ്യുമ്പോൾ ഉപയോഗിക്കുന്ന പകരം സന്ദേശം
rules.filterStderr അല്ല പിന്നീടുള്ള ഫിൽട്ടറിംഗ് ഘട്ടങ്ങൾക്കുമുമ്പ് സാധാരണ stderr പ്രിഫിക്സുകൾ നോർമലൈസ് ചെയ്യുക
preserve.errorPatterns അല്ല ചുരുക്കലിനുശേഷവും നിലനിൽക്കേണ്ട പിശക് വരികൾ
preserve.summaryPatterns അല്ല ചുരുക്കലിനുശേഷവും നിലനിൽക്കേണ്ട സംഗ്രഹ വരികൾ
tests[] അല്ല RTK പരിശോധനാ ഗേറ്റിൽ ഉപയോഗിക്കുന്ന ഇൻലൈൻ സ്ഥിരീകരണ സാമ്പിളുകൾ

RTK ഡിക്ലറേറ്റീവ് ഘട്ടങ്ങൾ ഈ ക്രമത്തിൽ പ്രയോഗിക്കുന്നു: stripAnsi, filterStderr, replace, matchOutput, dropPatterns/includePatterns, truncateLineAt, headLines/tailLines, maxLines, തുടർന്ന് onEmpty.

ഇഷ്ടാനുസൃത ഫിൽട്ടറുകൾ താഴെപ്പറയുന്ന ഉറവിടങ്ങളിൽനിന്ന് ലോഡ് ചെയ്യാം:

  1. പൊരുത്തപ്പെടുന്ന .rtk/trust.json ഹാഷ് നിലവിലുണ്ടെങ്കിൽ മാത്രം, അല്ലെങ്കിൽ trustProjectFilters പ്രവർത്തനക്ഷമമാക്കിയിട്ടുണ്ടെങ്കിൽ, പ്രോജക്റ്റിലെ .rtk/filters.json ഫയലുകളിൽനിന്ന്.
  2. ഗ്ലോബൽ DATA_DIR/rtk/filters.json.
  3. ബിൽറ്റ്-ഇൻ ഫിൽട്ടറുകൾ.

പ്രോജക്റ്റ്/ഗ്ലോബൽ ഇഷ്ടാനുസൃത ഫയലുകളിൽ ഒരു ഫിൽട്ടർ ഒബ്ജക്റ്റോ ഫിൽട്ടർ ഒബ്ജക്റ്റുകളുടെ ഒരു അറേയോ ഉണ്ടായിരിക്കാം. അസാധുവായ ഇഷ്ടാനുസൃത ഫിൽട്ടറുകൾ ഡയഗ്നോസ്റ്റിക്സ് സഹിതം ഒഴിവാക്കപ്പെടും; അസാധുവായ ബിൽറ്റ്-ഇൻ ഫിൽട്ടറുകൾ വാലിഡേഷൻ പരാജയപ്പെടാൻ കാരണമാകും.

പ്രോജക്റ്റ് ട്രസ്റ്റ് ഫയൽ:

{
  "filtersSha256": "0123456789abcdef..."
}

എൻവയോൺമെന്റ് ഓവർറൈഡായ OMNIROUTE_RTK_TRUST_PROJECT_FILTERS=1, ഹാഷ് ഇല്ലാതെയും പ്രോജക്റ്റ് ഫിൽട്ടറുകളെ വിശ്വസിക്കുന്നു; ഇത് നിയന്ത്രിതമായ ലോക്കൽ ഡെവലപ്മെന്റിൽ മാത്രം ഉപയോഗിക്കണം.

സുരക്ഷാ നിയമങ്ങൾ

  • നിയമങ്ങൾ ഐഡംപൊട്ടന്റായി നിലനിർത്തുക: ഒരേ ഫിൽട്ടർ രണ്ടുതവണ പ്രവർത്തിപ്പിക്കുന്നത് ഔട്ട്പുട്ടിനെ കേടാക്കരുത്.
  • സാധ്യമാകുന്നിടത്ത് കൃത്യമായ പിശക് വാചകം, ഫയൽ പാതകൾ, ലൈൻ നമ്പറുകൾ, കമാൻഡ് സംഗ്രഹങ്ങൾ എന്നിവ മാറ്റമില്ലാതെ നിലനിർത്തുക.
  • കോഡ് ബ്ലോക്കുകൾ, JSON പേലോഡുകൾ, URLs, അല്ലെങ്കിൽ രഹസ്യങ്ങൾ എന്നിവ പരിഷ്കരിക്കുന്ന നിയമങ്ങൾ ഒഴിവാക്കുക.
  • ഡിറ്റക്ടർ/ഫിൽട്ടർ ടെസ്റ്റുകളിൽ പുതിയ കമാൻഡ് കുടുംബങ്ങൾക്കായി യൂണിറ്റ് ടെസ്റ്റ് കവറേജ് ചേർക്കുക.
  • ഓരോ ബിൽറ്റ്-ഇൻ ഫിൽട്ടറിലേക്കും പങ്കിട്ട ഇഷ്ടാനുസൃത ഫിൽട്ടറുകളിലേക്കും tests[] സാമ്പിളുകൾ ചേർക്കുക.

സാധൂകരണം

റൂൾ പാക്കുകൾ ഉപയോഗിക്കുന്നതിന് മുമ്പ് സാധൂകരിക്കപ്പെടുന്നു. തകരാറുള്ള റിലീസ് അസറ്റുകൾ വിതരണം ചെയ്യുന്നതിനുമുമ്പ് കണ്ടെത്താനായി, ബിൽറ്റ്-ഇൻ Caveman പാക്കുകളും ബിൽറ്റ്-ഇൻ RTK ഫിൽട്ടറുകളും സാധൂകരണ സമയത്ത് ഉടനടി പരാജയപ്പെടുന്നു. പാഴ്സിങ് അല്ലെങ്കിൽ ട്രസ്റ്റ് സാധൂകരണം പരാജയപ്പെടുമ്പോൾ, ഇഷ്ടാനുസൃത RTK ഫിൽട്ടറുകൾ ഡയഗ്നോസ്റ്റിക്സ് സഹിതം ഒഴിവാക്കപ്പെടുന്നു.

കേന്ദ്രീകൃത സാധൂകരണം:

node --import tsx/esm --test tests/unit/compression/rule-loader.test.ts tests/unit/compression/language-packs.test.ts
node --import tsx/esm --test tests/unit/compression/rtk-verify.test.ts tests/unit/compression/rtk-dsl-pipeline.test.ts