本文へスキップ
Skillpedia
分析とスプレッドシート14k · #11149

extract

できること

このスキルは、ファイルまたは文章に対して抽出の工程を一通り実行し、固有名詞、関係、出来事、単純な主語・述語・目的語の事実を見つけます。書かれた資料から構造化された事実を得たい人向けです。

使う場面

  • ✓文書があり、その中の名前、関係、出来事を表にして一覧にしたいとき。
  • ✓事実を抜き出す前に、代名詞や別名を解決したいとき。
  • ✓抽出された結果に品質上の警告がないかを確認したいとき。

スキルのリンク

https://github.com/semantica-agi/semantica/blob/main/plugins/skills/extract/SKILL.md

コピーしてAI(Claude、ChatGPT、Cursor)に貼り付け、指示に従うよう頼んでください。

使い方

いちばん簡単な方法:メッセージをコピーしてAIに貼り付けるだけ。AIがスキルを読んで指示に従います。

貼り付け用メッセージ

このスキルを使って手伝ってください:https://github.com/semantica-agi/semantica/blob/main/plugins/skills/extract/SKILL.md このリンクのSKILL.mdファイルを読んで、私の作業でその指示に従ってください。
こういうスキルを、AIが自分で見つけてくれたら?無料のSkillpedia MCPをインストール。1行で、作業の前に15,000+のスキルから探してくれます。1分でインストール →

AIへの頼み方の例

“この契約書ファイルから、人、会社、重要な出来事を抜き出し、品質に関する警告があれば一覧にしてください。”

毎週5つの新しいスキル。1分で読めます。

仕組み

エージェントは文章を読み、エンティティと関係を見つけ、代名詞がどの名前を指すかを判断し、主語・述語・目的語の事実を組み立てて、検証の確認を実行します。結果は表として返され、警告があれば一緒に表示されます。

技術的な内容(元のSKILL.md)

作者による元のテキスト(英語)をGitHubからそのまま表示しています。

/semantica:extract

Run the full extraction pipeline. Usage: /semantica:extract [file_path | "inline text"]

$ARGUMENTS = file path, inline text in quotes, or blank (uses active editor file).


Steps

1. Resolve the source.

  • If $ARGUMENTS is a readable file path → text = open(path).read()
  • If it's quoted inline text → use directly
  • If blank → use the active editor file

2. Clear the result cache to prevent cross-invocation pollution:

from semantica.semantic_extract.cache import extraction_cache
extraction_cache.clear()

3. Run the full pipeline:

from semantica.semantic_extract import (
    NamedEntityRecognizer,
    RelationExtractor,
    EventDetector,
    CoreferenceResolver,
    TripletExtractor,
    ExtractionValidator,
)

# Named Entity Recognition
ner = NamedEntityRecognizer()
entities = ner.extract(text)

# Relation Extraction
rel = RelationExtractor()
relations = rel.extract(text)

# Event Detection
evt = EventDetector()
events = evt.extract(text)

# Coreference Resolution — resolve pronouns/aliases before extraction
coref = CoreferenceResolver()
resolved_text = coref.resolve(text)

# Triplet Extraction (subject–predicate–object)
triplet = TripletExtractor()
triplets = triplet.extract(resolved_text)

# Validate quality
validator = ExtractionValidator()
issues = validator.validate(entities, relations)

4. Report validator warnings above results:

⚠ ExtractionValidator: <warning message>

5. Return results as Markdown tables:

Entities (N total)

Label Type Confidence Span

Relations (M total)

Source Relation Type Target Confidence

Events (K total)

Label Type Participants Confidence

Triplets (J total)

Subject Predicate Object Confidence

6. Summary line:

Extracted: N entities, M relations, K events, J triplets — from <source>

For large files (>50KB), process in chunks and show a progress indicator. Highlight any entities appearing in the context graph already (ContextGraph.has_node(label)) with [in graph] tag.

よくある質問

照応の解決とは何ですか?

「彼女」や「その会社」などの語がどの名前を指すかを判断し、事実を正しいものにひもづけることです。

どんな結果が返されますか?

エンティティ、関係、出来事、トリプルの表と、検証ツールの警告です。

編集中のファイルに対して実行できますか?

はい。ファイルが指定されていなければ、エディターで開いているファイルを使えます。

詳細

作者による元の説明

Run the full Semantica semantic extraction pipeline on a file or selected text — NER, relations, events, coreference resolution, triplets, and validation. Clears result cache before each run. Returns Markdown tables with entity/relation/event/triplet results and inline validator warnings.

repo: semantica-agi/semantica

人気

GitHubのスター
14k
ランキング
#11149
ライセンス
MIT
更新日
2026/11/2

このスキルは役に立ちますか?

0

ログイン して投票しましょう。

コメント

  • …

このリポジトリの他のスキル

似ているスキル