the phrasing cap drops every option carrying an optional slot, so a locale loses the slot

Open
#682 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
74/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Active
Tech stack
python
Domain
localization

Research direction

Start with tools/gapfill_skill.sh and trace the translation layer's option-picking step, especially the content-word comparison described in the issue. Reproduce with ovos-skill-weather and fa-IR, then use the humidity.intent grep commands and locale_gate.py to confirm that each distinct slot set survives the cap and slot_survival passes.

Written by the indexing model from the issue text.

Description

Auto-generated by Claude, reviewed by a maintainer before posting.

The per-line phrasing cap drops every option that carries an optional slot,
so a drafted locale loses a slot the reference declares and the speaker
loses the question.

Observed

ovos-skill-weather en-US line:

(current|the) humidity [level] [right now] [in {location}]

The cap keeps at most four phrasings and takes a later option only when it
differs from every kept option by a content word. A slot name is not a word
of the phrasing, so [in {location}] adds only the word in, and the
location variant never differs by a content word. Every location option was
dropped.

Five fa-IR intent files of ovos-skill-weather came out with no
{location} at all: humidity, is_wind, next_rain, sunrise and
sunset. 42 reference lines carry {location} across those five files and
the draft carries none, so a Persian speaker cannot ask about another city.
verify_locales.py reports 0 problems, because every file exists and is not
empty; locale_gate.py reports it as slot_survival FAIL.

Expected

The cap counts phrasings, not questions. Every distinct slot set among a
line's options keeps at least one line, past the cap. A lost slot is a lost
question and a line is cheap.

Reproduce

tools/gapfill_skill.sh ovos-skill-weather fa-IR
grep -c '{location}' locale/en-US/intents/humidity.intent   # 8
grep -c '{location}' locale/fa-IR/intents/humidity.intent   # 0

Where

The option-picking step of the translation layer the gap-fill route calls,
and the content-word test it uses to tell two phrasings apart.

Dominant language
Python
Stars
8
Forks
4
PR merge metrics
No merged PRs in 30d

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from OpenVoiceOS/ovos-localize

All issues in OpenVoiceOS/ovos-localize

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.