Repository navigation
lingrep 0.8.1
lingrep 0.8.1
This release fixes problems found in classes using 0.8.0. Install it as before:
curl --proto '=https' --proto-redir '=https' --tlsv1.2 -fsSLO https://github.com/borh/lingrep/releases/latest/download/install.sh
sh install.shFixes
Writing tables and corpora
- On macOS,
ling summarize --write-tablecould fail with "too many open
files" on a large corpus.lingnow raises its own open-file limit and
sizes its temporary files to fit, soulimit -nis no longer needed. When
the limit is low,lingstill finishes and prints
warning[open_file_limit]. When even the smallest layout cannot fit,
lingstops before scanning and reports how many more open files it
requires. - In 0.8.1,
ling corpus buildunder/mnt/cstill fails with
"Permission denied (os error 13)". Use
0.8.2 or write the
corpus to a directory inside WSL, such as~/corpora. Correction: this
note first said that corpora could be written to/mnt/cin 0.8.1. ling analyzer prepareon a FAT or exFAT drive, such as many USB sticks,
failed during setup, after downloading, because the drive cannot hold
symbolic links. It now checks before downloading. If the check fails, it
reports an error that suggests an--outputdirectory on a drive that
supports them.ling corpus build --input-format plain DIRreads every.txtfile under
DIR, including subdirectories, as one document each. 0.8.0 rejected a
directory of.txtfiles. A directory without--input-formatis still
read as Markdown, and the error now suggests the flag when no Markdown
files are found.- A pattern that produced many matches in a few sentences could stop a run
although each sentence was within the output budget. Such batches are now
retried in smaller groups. A single sentence that still exceeds the budget
reports an error that suggests narrowing the pattern.
The question page and the Workbench
- With a catalog such as
class6.lx, the Workbench's "Derive compounds"
(複合項目を生成) could use all available memory. Compound derivation is
now off by default and stops at a fixed limit with a message that says to
turn it off or search fewer definitions. Links from the question page to
the analysis tools open the Workbench on the current pattern and corpus
with compounds off. - A completed search whose results were too large to display was reported as
failed. It is now shown as complete, and "Download all results as JSONL"
saves every match, including examples too large to preview. The link
appears only when the export can succeed, and it is still there after
reloading the page. - An example opened while a search was still running stays open when the
search finishes, and the search controls no longer move while results
arrive. - A saved question link records which catalog it was made with. If the
server's catalog has changed since, the page offers two choices: search
with the current catalog, or open the default question. - Result lists can be navigated with the arrow keys, Home and End, with a
single Tab stop for the list. - In Safari, Escape now closes an open example after you click one of its
tokens. Focus returns to the result line that opened it. - When the server rejects a Workbench download, the message is in Japanese
if the interface is in Japanese.
Serving prepared corpora
ling serve no longer requires a dictionary when every --corpus is a
prepared .lingcorpus artifact, so an instructor can hand out corpora and
count tables without the dictionary:
ling serve --corpus natsume=natsume.lingcorpus --count-table natsume.lingtable \
--patterns patterns/class6.lx --pattern-root patternsSource corpora and the Workbench's sample analysis still need a dictionary,
and their errors say how to supply one.
GiNZA transformer extras
Installing the spaCy adapter wheel with the electra or bert-large extra
failed in 0.8.0 because the extras' Transformers pin conflicted with
spacy-transformers. The extras now resolve to Transformers 4.53.2, the newest
version that spacy-transformers 1.4 accepts. To use Transformers 4.57.6, as the
adapter's own lock file does, put transformers==4.57.6 in overrides.txt
and add --override overrides.txt to uv pip install. ling analyzer prepare ginza installs the same locked versions as before.
Upgrading
Corpora and count tables prepared with 0.8.0 work with 0.8.1 without
rebuilding. This was checked with a Vibrato/UniDic corpus and a GiNZA corpus
built by the 0.8.0 release: ling corpus inspect --verify, ling matches,
ling summarize, ling summarize --write-table, ling table on a 0.8.0
count table, and ling serve (question page, Workbench and Frequencies) all
succeed, and ling matches returns the same records as 0.8.0. Reading a
prepared corpus does not run its analyzer.
Running ling corpus build again on the same source with the same
dictionary reuses the existing 0.8.0 Vibrato/UniDic artifact instead of
writing a new one.
GiNZA and Stanza analyzers
The identity of a GiNZA (spaCy) or Stanza analyzer now comes from the
adapter's semantics revision, the versions of the installed packages, and
the hashes of the model files. lingrep changes the semantics revision only
when the adapter's output changes. The identity no longer depends on the
bytes of lingrep's adapter code, so a later lingrep release that leaves the
analysis unchanged prepares an analyzer with the same identity. A change to any installed
package version, including a patch release, gives a new identity.
Under 0.8.1, a GiNZA analyzer therefore has a different identity from the
one 0.8.0 recorded, although it produces the same tokens. Nothing needs to
be prepared again:
- Corpora and count tables built with a 0.8.0 analyzer keep working, as
above. - A 0.8.0 analyzer still runs under 0.8.1 through
--analyzer-config. ling corpus buildof a source that 0.8.0 already built writes a second
artifact beside the 0.8.0 one, with an analyzer prepared by either
release, and prints a note naming "analyzer semantics" as the
difference. Later builds with the same analyzer reuse that artifact.
To prepare a 0.8.1 analyzer, choose a new directory; ling analyzer prepare
rejects one prepared by 0.8.0:
ling analyzer prepare ginza --output ./analyzers/ginza-0.8.1ling 0.8.0 cannot run an analyzer prepared by 0.8.1. ling now also
rejects a 0.8.1 analyzer whose adapter code has changed since it was
prepared; analyzers prepared by 0.8.0 are not checked.
Adapter wheels use version 0.8.1. See the
changelog for the complete list of
changes.