@shuji-bonji/pdf-reader-mcp 0.12.0 → 0.14.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +181 -0
- package/dist/constants.js.map +1 -1
- package/dist/errors.d.ts.map +1 -1
- package/dist/errors.js.map +1 -1
- package/dist/index.js +8 -2
- package/dist/index.js.map +1 -1
- package/dist/schemas/common.d.ts +2 -2
- package/dist/schemas/common.d.ts.map +1 -1
- package/dist/schemas/common.js +1 -2
- package/dist/schemas/common.js.map +1 -1
- package/dist/schemas/tier1.d.ts +22 -98
- package/dist/schemas/tier1.d.ts.map +1 -1
- package/dist/schemas/tier2.d.ts +18 -78
- package/dist/schemas/tier2.d.ts.map +1 -1
- package/dist/schemas/tier3.d.ts +6 -26
- package/dist/schemas/tier3.d.ts.map +1 -1
- package/dist/services/content-stream-service.js.map +1 -1
- package/dist/services/page-renderer.d.ts +25 -0
- package/dist/services/page-renderer.d.ts.map +1 -1
- package/dist/services/page-renderer.js +160 -62
- package/dist/services/page-renderer.js.map +1 -1
- package/dist/services/page-renderer.worker.mjs +104 -0
- package/dist/services/pdfjs-service.js.map +1 -1
- package/dist/services/reading-scope.d.ts +115 -0
- package/dist/services/reading-scope.d.ts.map +1 -0
- package/dist/services/reading-scope.js +123 -0
- package/dist/services/reading-scope.js.map +1 -0
- package/dist/services/struct-tree-service.js.map +1 -1
- package/dist/services/struct-tree-walker.js.map +1 -1
- package/dist/services/text-extractability-service.js.map +1 -1
- package/dist/services/validation-service.d.ts.map +1 -1
- package/dist/services/validation-service.js +78 -15
- package/dist/services/validation-service.js.map +1 -1
- package/dist/tools/index.d.ts +1 -1
- package/dist/tools/index.d.ts.map +1 -1
- package/dist/tools/index.js +0 -4
- package/dist/tools/index.js.map +1 -1
- package/dist/tools/tier1/get-metadata.d.ts +1 -1
- package/dist/tools/tier1/get-metadata.d.ts.map +1 -1
- package/dist/tools/tier1/get-metadata.js +0 -3
- package/dist/tools/tier1/get-metadata.js.map +1 -1
- package/dist/tools/tier1/get-page-count.d.ts +1 -1
- package/dist/tools/tier1/get-page-count.d.ts.map +1 -1
- package/dist/tools/tier1/get-page-count.js +0 -3
- package/dist/tools/tier1/get-page-count.js.map +1 -1
- package/dist/tools/tier1/read-images.d.ts +1 -1
- package/dist/tools/tier1/read-images.d.ts.map +1 -1
- package/dist/tools/tier1/read-images.js +0 -3
- package/dist/tools/tier1/read-images.js.map +1 -1
- package/dist/tools/tier1/read-text.d.ts +1 -1
- package/dist/tools/tier1/read-text.d.ts.map +1 -1
- package/dist/tools/tier1/read-text.js +49 -37
- package/dist/tools/tier1/read-text.js.map +1 -1
- package/dist/tools/tier1/read-url.d.ts +1 -1
- package/dist/tools/tier1/read-url.d.ts.map +1 -1
- package/dist/tools/tier1/read-url.js +62 -41
- package/dist/tools/tier1/read-url.js.map +1 -1
- package/dist/tools/tier1/render-page.d.ts +1 -1
- package/dist/tools/tier1/render-page.d.ts.map +1 -1
- package/dist/tools/tier1/render-page.js +2 -3
- package/dist/tools/tier1/render-page.js.map +1 -1
- package/dist/tools/tier1/search-text.d.ts +1 -1
- package/dist/tools/tier1/search-text.d.ts.map +1 -1
- package/dist/tools/tier1/search-text.js +66 -58
- package/dist/tools/tier1/search-text.js.map +1 -1
- package/dist/tools/tier1/summarize.d.ts +1 -1
- package/dist/tools/tier1/summarize.d.ts.map +1 -1
- package/dist/tools/tier1/summarize.js +71 -40
- package/dist/tools/tier1/summarize.js.map +1 -1
- package/dist/tools/tier2/extract-structured-text.d.ts +1 -1
- package/dist/tools/tier2/extract-structured-text.d.ts.map +1 -1
- package/dist/tools/tier2/extract-structured-text.js +38 -31
- package/dist/tools/tier2/extract-structured-text.js.map +1 -1
- package/dist/tools/tier2/extract-tables.d.ts +1 -1
- package/dist/tools/tier2/extract-tables.d.ts.map +1 -1
- package/dist/tools/tier2/extract-tables.js +0 -8
- package/dist/tools/tier2/extract-tables.js.map +1 -1
- package/dist/tools/tier2/inspect-annotations.d.ts +1 -1
- package/dist/tools/tier2/inspect-annotations.d.ts.map +1 -1
- package/dist/tools/tier2/inspect-annotations.js +0 -3
- package/dist/tools/tier2/inspect-annotations.js.map +1 -1
- package/dist/tools/tier2/inspect-fonts.d.ts +1 -1
- package/dist/tools/tier2/inspect-fonts.d.ts.map +1 -1
- package/dist/tools/tier2/inspect-fonts.js +0 -3
- package/dist/tools/tier2/inspect-fonts.js.map +1 -1
- package/dist/tools/tier2/inspect-signatures.d.ts +1 -1
- package/dist/tools/tier2/inspect-signatures.d.ts.map +1 -1
- package/dist/tools/tier2/inspect-signatures.js +0 -3
- package/dist/tools/tier2/inspect-signatures.js.map +1 -1
- package/dist/tools/tier2/inspect-structure.d.ts +1 -1
- package/dist/tools/tier2/inspect-structure.d.ts.map +1 -1
- package/dist/tools/tier2/inspect-structure.js +0 -3
- package/dist/tools/tier2/inspect-structure.js.map +1 -1
- package/dist/tools/tier2/inspect-tags.d.ts +1 -1
- package/dist/tools/tier2/inspect-tags.d.ts.map +1 -1
- package/dist/tools/tier2/inspect-tags.js +0 -3
- package/dist/tools/tier2/inspect-tags.js.map +1 -1
- package/dist/tools/tier2/locate-objects.d.ts +1 -1
- package/dist/tools/tier2/locate-objects.d.ts.map +1 -1
- package/dist/tools/tier2/locate-objects.js +0 -3
- package/dist/tools/tier2/locate-objects.js.map +1 -1
- package/dist/tools/tier3/compare-structure.d.ts +1 -1
- package/dist/tools/tier3/compare-structure.d.ts.map +1 -1
- package/dist/tools/tier3/compare-structure.js +2 -3
- package/dist/tools/tier3/compare-structure.js.map +1 -1
- package/dist/tools/tier3/validate-metadata.d.ts +1 -1
- package/dist/tools/tier3/validate-metadata.d.ts.map +1 -1
- package/dist/tools/tier3/validate-metadata.js +0 -3
- package/dist/tools/tier3/validate-metadata.js.map +1 -1
- package/dist/tools/tier3/validate-tagged.d.ts +1 -1
- package/dist/tools/tier3/validate-tagged.d.ts.map +1 -1
- package/dist/tools/tier3/validate-tagged.js +2 -3
- package/dist/tools/tier3/validate-tagged.js.map +1 -1
- package/dist/types.d.ts +56 -13
- package/dist/types.d.ts.map +1 -1
- package/dist/utils/batch-processor.js.map +1 -1
- package/dist/utils/error-handler.d.ts.map +1 -1
- package/dist/utils/error-handler.js +15 -2
- package/dist/utils/error-handler.js.map +1 -1
- package/dist/utils/formatter.d.ts.map +1 -1
- package/dist/utils/formatter.js +41 -17
- package/dist/utils/formatter.js.map +1 -1
- package/package.json +9 -6
|
@@ -1,11 +1,8 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* extract_structured_text - structure-preserving text extraction (M-8).
|
|
3
|
-
*/
|
|
4
1
|
import { ResponseFormat } from '../../constants.js';
|
|
5
2
|
import { ExtractStructuredTextSchema, } from '../../schemas/tier2.js';
|
|
3
|
+
import { bothFailedError, bothHalves, formatReadingScope } from '../../services/reading-scope.js';
|
|
6
4
|
import { extractStructuredText } from '../../services/struct-tree-service.js';
|
|
7
5
|
import { observeExtractability, summarizeExtractability, } from '../../services/text-extractability-service.js';
|
|
8
|
-
import { handleStructuredError } from '../../utils/error-handler.js';
|
|
9
6
|
import { formatStructuredTextMarkdown, truncateIfNeeded } from '../../utils/formatter.js';
|
|
10
7
|
export function registerExtractStructuredText(server) {
|
|
11
8
|
server.registerTool('extract_structured_text', {
|
|
@@ -28,6 +25,8 @@ Returns:
|
|
|
28
25
|
Each element has: role, depth (nesting; top level is 0), text, pages, and optionally
|
|
29
26
|
alt / label / rows / boxes / boxNote.
|
|
30
27
|
|
|
28
|
+
\`scope\` says which of the two readings behind that answer were done — reading the structure tree, and observing whether the characters under it have a route to Unicode (ISO 32000-2 §9.10.1). When the structure tree could not be read, \`isTagged\` and \`elements\` are \`null\` rather than \`false\` and \`[]\`: "not read" and "read and found no tags" are different answers.
|
|
29
|
+
|
|
31
30
|
The list is flat with a depth field rather than nested — a depth-first pre-order plus
|
|
32
31
|
depth encodes the tree exactly, so nothing is lost. Table is the exception and carries
|
|
33
32
|
rows, because a table is two-dimensional and depth cannot express "row 2, column 3".
|
|
@@ -87,37 +86,45 @@ Examples:
|
|
|
87
86
|
openWorldHint: false,
|
|
88
87
|
},
|
|
89
88
|
}, async (params) => {
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
]);
|
|
103
|
-
result.extractability = observations;
|
|
104
|
-
const raw = params.response_format === ResponseFormat.JSON
|
|
105
|
-
? JSON.stringify(result, null, 2)
|
|
106
|
-
: [
|
|
107
|
-
...summarizeExtractability(observations),
|
|
108
|
-
'',
|
|
109
|
-
formatStructuredTextMarkdown(result),
|
|
110
|
-
].join('\n');
|
|
111
|
-
const { text } = truncateIfNeeded(raw);
|
|
112
|
-
return { content: [{ type: 'text', text }] };
|
|
113
|
-
}
|
|
114
|
-
catch (error) {
|
|
115
|
-
const err = handleStructuredError(error);
|
|
89
|
+
// 🔴 構造木の読み取りと §9.10.1 の観測は別々に失敗しうる。
|
|
90
|
+
const { text: structured, observation, scope, } = await bothHalves(() => extractStructuredText(params.file_path, {
|
|
91
|
+
pages: params.pages,
|
|
92
|
+
roles: params.roles,
|
|
93
|
+
includeBbox: params.include_bbox,
|
|
94
|
+
}),
|
|
95
|
+
// #21: logical order does not make characters convertible. A tagged
|
|
96
|
+
// page drawn with an Identity-H font that has no /ToUnicode returns a
|
|
97
|
+
// correct tree over unreadable text, and that has to be visible here
|
|
98
|
+
// too — otherwise this is the one path that still hides it.
|
|
99
|
+
() => observeExtractability(params.file_path, params.pages));
|
|
100
|
+
if (!structured.ok && !observation.ok) {
|
|
116
101
|
return {
|
|
117
|
-
content: [
|
|
102
|
+
content: [
|
|
103
|
+
{
|
|
104
|
+
type: 'text',
|
|
105
|
+
text: JSON.stringify(bothFailedError(structured.error, observation.error), null, 2),
|
|
106
|
+
},
|
|
107
|
+
],
|
|
118
108
|
isError: true,
|
|
119
109
|
};
|
|
120
110
|
}
|
|
111
|
+
const observations = observation.ok ? observation.value : [];
|
|
112
|
+
// 構造木が読めなかったときは null を置く。false は「タグが無いと観測した」であり、
|
|
113
|
+
// 読めなかったこととは違う。
|
|
114
|
+
const result = structured.ok
|
|
115
|
+
? { scope, ...structured.value, extractability: observations }
|
|
116
|
+
: { scope, isTagged: null, lang: null, elements: null, extractability: observations };
|
|
117
|
+
const raw = params.response_format === ResponseFormat.JSON
|
|
118
|
+
? JSON.stringify(result, null, 2)
|
|
119
|
+
: [
|
|
120
|
+
...formatReadingScope(scope),
|
|
121
|
+
'',
|
|
122
|
+
...(observation.ok ? summarizeExtractability(observations) : []),
|
|
123
|
+
'',
|
|
124
|
+
formatStructuredTextMarkdown(result),
|
|
125
|
+
].join('\n');
|
|
126
|
+
const { text } = truncateIfNeeded(raw);
|
|
127
|
+
return { content: [{ type: 'text', text }] };
|
|
121
128
|
});
|
|
122
129
|
}
|
|
123
130
|
//# sourceMappingURL=extract-structured-text.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"extract-structured-text.js","sourceRoot":"","sources":["../../../src/tools/tier2/extract-structured-text.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"extract-structured-text.js","sourceRoot":"","sources":["../../../src/tools/tier2/extract-structured-text.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AACpD,OAAO,EAEL,2BAA2B,GAC5B,MAAM,wBAAwB,CAAC;AAChC,OAAO,EAAE,eAAe,EAAE,UAAU,EAAE,kBAAkB,EAAE,MAAM,iCAAiC,CAAC;AAClG,OAAO,EAAE,qBAAqB,EAAE,MAAM,uCAAuC,CAAC;AAC9E,OAAO,EACL,qBAAqB,EACrB,uBAAuB,GACxB,MAAM,+CAA+C,CAAC;AAEvD,OAAO,EAAE,4BAA4B,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAE1F,MAAM,UAAU,6BAA6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CAAC,CAAC,CAAC,EAAE,CAAC;QAC7D,iDAAiD;QACjD,gBAAgB;QAChB,MAAM,MAAM,GAAyB,UAAU,CAAC,EAAE;YAChD,CAAC,CAAC,EAAE,KAAK,EAAE,GAAG,UAAU,CAAC,KAAK,EAAE,cAAc,EAAE,YAAY,EAAE;YAC9D,CAAC,CAAC,EAAE,KAAK,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,QAAQ,EAAE,IAAI,EAAE,cAAc,EAAE,YAAY,EAAE,CAAC;QAExF,MAAM,GAAG,GACP,MAAM,CAAC,eAAe,KAAK,cAAc,CAAC,IAAI;YAC5C,CAAC,CAAC,IAAI,CAAC,SAAS,CAAC,MAAM,EAAE,IAAI,EAAE,CAAC,CAAC;YACjC,CAAC,CAAC;gBACE,GAAG,kBAAkB,CAAC,KAAK,CAAC;gBAC5B,EAAE;gBACF,GAAG,CAAC,WAAW,CAAC,EAAE,CAAC,CAAC,CAAC,uBAAuB,CAAC,YAAY,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC;gBAChE,EAAE;gBACF,4BAA4B,CAAC,MAAM,CAAC;aACrC,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QAEnB,MAAM,EAAE,IAAI,EAAE,GAAG,gBAAgB,CAAC,GAAG,CAAC,CAAC;QACvC,OAAO,EAAE,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAe,EAAE,IAAI,EAAE,CAAC,EAAE,CAAC;IACxD,CAAC,CACF,CAAC;AACJ,CAAC"}
|
|
@@ -6,6 +6,6 @@
|
|
|
6
6
|
* such as 国税庁 新旧対照表 / 帳票, where pure reading-order extraction
|
|
7
7
|
* collapses two-column tables into ambiguous text.
|
|
8
8
|
*/
|
|
9
|
-
import type { McpServer } from '@modelcontextprotocol/
|
|
9
|
+
import type { McpServer } from '@modelcontextprotocol/server';
|
|
10
10
|
export declare function registerExtractTables(server: McpServer): void;
|
|
11
11
|
//# sourceMappingURL=extract-tables.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"extract-tables.d.ts","sourceRoot":"","sources":["../../../src/tools/tier2/extract-tables.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;
|
|
1
|
+
{"version":3,"file":"extract-tables.d.ts","sourceRoot":"","sources":["../../../src/tools/tier2/extract-tables.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AACH,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,8BAA8B,CAAC;AAO9D,wBAAgB,qBAAqB,CAAC,MAAM,EAAE,SAAS,GAAG,IAAI,CAkE7D"}
|
|
@@ -1,11 +1,3 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* extract_tables - Tagged PDF Table → Markdown extraction.
|
|
3
|
-
*
|
|
4
|
-
* Walks the structure tree (Tagged PDF only) and emits every `<Table>`
|
|
5
|
-
* subtree as a Markdown table or a JSON object. Designed for documents
|
|
6
|
-
* such as 国税庁 新旧対照表 / 帳票, where pure reading-order extraction
|
|
7
|
-
* collapses two-column tables into ambiguous text.
|
|
8
|
-
*/
|
|
9
1
|
import { ResponseFormat } from '../../constants.js';
|
|
10
2
|
import { ExtractTablesSchema } from '../../schemas/tier2.js';
|
|
11
3
|
import { extractTables } from '../../services/struct-tree-service.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"extract-tables.js","sourceRoot":"","sources":["../../../src/tools/tier2/extract-tables.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"extract-tables.js","sourceRoot":"","sources":["../../../src/tools/tier2/extract-tables.ts"],"names":[],"mappings":"AASA,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AACpD,OAAO,EAA2B,mBAAmB,EAAE,MAAM,wBAAwB,CAAC;AACtF,OAAO,EAAE,aAAa,EAAE,MAAM,uCAAuC,CAAC;AACtE,OAAO,EAAE,qBAAqB,EAAE,MAAM,8BAA8B,CAAC;AACrE,OAAO,EAAE,oBAAoB,EAA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|
|
|
1
1
|
/**
|
|
2
2
|
* inspect_annotations - PDF annotation analysis.
|
|
3
3
|
*/
|
|
4
|
-
import type { McpServer } from '@modelcontextprotocol/
|
|
4
|
+
import type { McpServer } from '@modelcontextprotocol/server';
|
|
5
5
|
export declare function registerInspectAnnotations(server: McpServer): void;
|
|
6
6
|
//# sourceMappingURL=inspect-annotations.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"inspect-annotations.d.ts","sourceRoot":"","sources":["../../../src/tools/tier2/inspect-annotations.ts"],"names":[],"mappings":"AAAA;;GAEG;
|
|
1
|
+
{"version":3,"file":"inspect-annotations.d.ts","sourceRoot":"","sources":["../../../src/tools/tier2/inspect-annotations.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,8BAA8B,CAAC;AAO9D,wBAAgB,0BAA0B,CAAC,MAAM,EAAE,SAAS,GAAG,IAAI,CA+ClE"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"inspect-annotations.js","sourceRoot":"","sources":["../../../src/tools/tier2/inspect-annotations.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"inspect-annotations.js","sourceRoot":"","sources":["../../../src/tools/tier2/inspect-annotations.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AACpD,OAAO,EAAgC,wBAAwB,EAAE,MAAM,wBAAwB,CAAC;AAChG,OAAO,EAAE,kBAAkB,EAAE,MAAM,iCAAiC,CAAC;AACrE,OAAO,EAAE,qBAAqB,EAAE,MAAM,8BAA8B,CAAC;AACrE,OAAO,EAAE,yBAAyB,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAEvF,MAAM,UAAU,0BAA0B,CAAC,MAAiB;IAC1D,MAAM,CAAC,YAAY,CACjB,qBAAqB,EACrB;QACE,KAAK,EAAE,yBAAyB;QAChC,WAAW,EAAE;;;;;;;;;;;;;wDAaqC;QAClD,WAAW,EAAE,wBAAwB;QACrC,WAAW,EAAE;YACX,YAAY,EAAE,IAAI;YAClB,eAAe,EAAE,KAAK;YACtB,cAAc,EAAE,IAAI;YACpB,aAAa,EAAE,KAAK;SACrB;KACF,EACD,KAAK,EAAE,MAA+B,EAAE,EAAE;QACxC,IAAI,CAAC;YACH,MAAM,QAAQ,GAAG,MAAM,kBAAkB,CAAC,MAAM,CAAC,SAAS,EAAE,MAAM,CAAC,KAAK,CAAC,CAAC;YAE1E,MAAM,GAAG,GACP,MAAM,CAAC,eAAe,KAAK,cAAc,CAAC,IAAI;gBAC5C,CAAC,CAAC,IAAI,CAAC,SAAS,CAAC,QAAQ,EAAE,IAAI,EAAE,CAAC,CAAC;gBACnC,CAAC,CAAC,yBAAyB,CAAC,QAAQ,CAAC,CAAC;YAE1C,MAAM,EAAE,IAAI,EAAE,GAAG,gBAAgB,CAAC,GAAG,CAAC,CAAC;YACvC,OAAO,EAAE,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAe,EAAE,IAAI,EAAE,CAAC,EAAE,CAAC;QACxD,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,MAAM,GAAG,GAAG,qBAAqB,CAAC,KAAK,CAAC,CAAC;YACzC,OAAO;gBACL,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAe,EAAE,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC,GAAG,EAAE,IAAI,EAAE,CAAC,CAAC,EAAE,CAAC;gBACxE,OAAO,EAAE,IAAI;aACd,CAAC;QACJ,CAAC;IACH,CAAC,CACF,CAAC;AACJ,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* inspect_fonts - PDF font analysis.
|
|
3
3
|
*/
|
|
4
|
-
import type { McpServer } from '@modelcontextprotocol/
|
|
4
|
+
import type { McpServer } from '@modelcontextprotocol/server';
|
|
5
5
|
export declare function registerInspectFonts(server: McpServer): void;
|
|
6
6
|
//# sourceMappingURL=inspect-fonts.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"inspect-fonts.d.ts","sourceRoot":"","sources":["../../../src/tools/tier2/inspect-fonts.ts"],"names":[],"mappings":"AAAA;;GAEG;
|
|
1
|
+
{"version":3,"file":"inspect-fonts.d.ts","sourceRoot":"","sources":["../../../src/tools/tier2/inspect-fonts.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,8BAA8B,CAAC;AAQ9D,wBAAgB,oBAAoB,CAAC,MAAM,EAAE,SAAS,GAAG,IAAI,CAwD5D"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"inspect-fonts.js","sourceRoot":"","sources":["../../../src/tools/tier2/inspect-fonts.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"inspect-fonts.js","sourceRoot":"","sources":["../../../src/tools/tier2/inspect-fonts.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AACpD,OAAO,EAA0B,kBAAkB,EAAE,MAAM,wBAAwB,CAAC;AACpF,OAAO,EAAE,sBAAsB,EAAE,MAAM,kCAAkC,CAAC;AAE1E,OAAO,EAAE,qBAAqB,EAAE,MAAM,8BAA8B,CAAC;AACrE,OAAO,EAAE,mBAAmB,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAEjF,MAAM,UAAU,oBAAoB,CAAC,MAAiB;IACpD,MAAM,CAAC,YAAY,CACjB,eAAe,EACf;QACE,KAAK,EAAE,mBAAmB;QAC1B,WAAW,EAAE;;;;;;;;;;;;wCAYqB;QAClC,WAAW,EAAE,kBAAkB;QAC/B,WAAW,EAAE;YACX,YAAY,EAAE,IAAI;YAClB,eAAe,EAAE,KAAK;YACtB,cAAc,EAAE,IAAI;YACpB,aAAa,EAAE,KAAK;SACrB;KACF,EACD,KAAK,EAAE,MAAyB,EAAE,EA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C,GAAG,EAAE,IAAI,EAAE,CAAC,CAAC,EAAE,CAAC;gBACxE,OAAO,EAAE,IAAI;aACd,CAAC;QACJ,CAAC;IACH,CAAC,CACF,CAAC;AACJ,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* inspect_signatures - PDF digital signature analysis.
|
|
3
3
|
*/
|
|
4
|
-
import type { McpServer } from '@modelcontextprotocol/
|
|
4
|
+
import type { McpServer } from '@modelcontextprotocol/server';
|
|
5
5
|
export declare function registerInspectSignatures(server: McpServer): void;
|
|
6
6
|
//# sourceMappingURL=inspect-signatures.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"inspect-signatures.d.ts","sourceRoot":"","sources":["../../../src/tools/tier2/inspect-signatures.ts"],"names":[],"mappings":"AAAA;;GAEG;
|
|
1
|
+
{"version":3,"file":"inspect-signatures.d.ts","sourceRoot":"","sources":["../../../src/tools/tier2/inspect-signatures.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,8BAA8B,CAAC;AAO9D,wBAAgB,yBAAyB,CAAC,MAAM,EAAE,SAAS,GAAG,IAAI,CAgDjE"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"inspect-signatures.js","sourceRoot":"","sources":["../../../src/tools/tier2/inspect-signatures.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"inspect-signatures.js","sourceRoot":"","sources":["../../../src/tools/tier2/inspect-signatures.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AACpD,OAAO,EAA+B,uBAAuB,EAAE,MAAM,wBAAwB,CAAC;AAC9F,OAAO,EAAE,iBAAiB,EAAE,MAAM,kCAAkC,CAAC;AACrE,OAAO,EAAE,qBAAqB,EAAE,MAAM,8BAA8B,CAAC;AACrE,OAAO,EAAE,wBAAwB,EAAE,gBAAgB,EAAE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
|
3
3
|
*/
|
|
4
|
-
import type { McpServer } from '@modelcontextprotocol/
|
|
4
|
+
import type { McpServer } from '@modelcontextprotocol/server';
|
|
5
5
|
export declare function registerInspectStructure(server: McpServer): void;
|
|
6
6
|
//# sourceMappingURL=inspect-structure.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"inspect-structure.d.ts","sourceRoot":"","sources":["../../../src/tools/tier2/inspect-structure.ts"],"names":[],"mappings":"AAAA;;GAEG;
|
|
1
|
+
{"version":3,"file":"inspect-structure.d.ts","sourceRoot":"","sources":["../../../src/tools/tier2/inspect-structure.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,8BAA8B,CAAC;AAO9D,wBAAgB,wBAAwB,CAAC,MAAM,EAAE,SAAS,GAAG,IAAI,CA8ChE"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"inspect-structure.js","sourceRoot":"","sources":["../../../src/tools/tier2/inspect-structure.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"inspect-structure.js","sourceRoot":"","sources":["../../../src/tools/tier2/inspect-structure.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AACpD,OAAO,EAA8B,sBAAsB,EAAE,MAAM,wBAAwB,CAAC;AAC5F,OAAO,EAAE,gBAAgB,EAAE,MAAM,kCAAkC,CAAC;AACpE,OAAO,EAAE,qBAAqB,EAAE,MAAM,8BAA8B,CAAC;AACrE,OAAO,EAAE,uBAAuB,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAErF,MAAM,UAAU,wBAAwB,CAAC,MAAiB;IACxD,MAAM,CAAC,YAAY,CACjB,mBAAmB,EACnB;QACE,KAAK,EAAE,uBAAuB;QAC9B,WAAW,EAAE;;;;;;;;;;;;8CAY2B;QACxC,WAAW,EAAE,sBAAsB;QACnC,WAAW,EAAE;YACX,YAAY,EAAE,IAAI;YAClB,eAAe,EAAE,KAAK;YACtB,cAAc,EAAE,IAAI;YACpB,aAAa,EAAE,KAAK;SACrB;KACF,EACD,KAAK,EAAE,MAA6B,EAAE,EAAE;QACtC,IAAI,CAAC;YACH,MAAM,QAAQ,GAAG,MAAM,gBAAgB,CAAC,MAAM,CAAC,SAAS,CAAC,CAAC;YAE1D,MAAM,GAAG,GACP,MAAM,CAAC,eAAe,KAAK,cAAc,CAAC,IAAI;gBAC5C,CAAC,CAAC,IAAI,CAAC,SAAS,CAAC,QAAQ,EAAE,IAAI,EAAE,CAAC,CAAC;gBACnC,CAAC,CAAC,uBAAuB,CAAC,QAAQ,CAAC,CAAC;YAExC,MAAM,EAAE,IAAI,EAAE,GAAG,gBAAgB,CAAC,GAAG,CAAC,CAAC;YACvC,OAAO,EAAE,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAe,EAAE,IAAI,EAAE,CAAC,EAAE,CAAC;QACxD,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,MAAM,GAAG,GAAG,qBAAqB,CAAC,KAAK,CAAC,CAAC;YACzC,OAAO;gBACL,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAe,EAAE,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC,GAAG,EAAE,IAAI,EAAE,CAAC,CAAC,EAAE,CAAC;gBACxE,OAAO,EAAE,IAAI;aACd,CAAC;QACJ,CAAC;IACH,CAAC,CACF,CAAC;AACJ,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* inspect_tags - Tagged PDF structure tree analysis.
|
|
3
3
|
*/
|
|
4
|
-
import type { McpServer } from '@modelcontextprotocol/
|
|
4
|
+
import type { McpServer } from '@modelcontextprotocol/server';
|
|
5
5
|
export declare function registerInspectTags(server: McpServer): void;
|
|
6
6
|
//# sourceMappingURL=inspect-tags.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"inspect-tags.d.ts","sourceRoot":"","sources":["../../../src/tools/tier2/inspect-tags.ts"],"names":[],"mappings":"AAAA;;GAEG;
|
|
1
|
+
{"version":3,"file":"inspect-tags.d.ts","sourceRoot":"","sources":["../../../src/tools/tier2/inspect-tags.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,8BAA8B,CAAC;AAO9D,wBAAgB,mBAAmB,CAAC,MAAM,EAAE,SAAS,GAAG,IAAI,CA8C3D"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"inspect-tags.js","sourceRoot":"","sources":["../../../src/tools/tier2/inspect-tags.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"inspect-tags.js","sourceRoot":"","sources":["../../../src/tools/tier2/inspect-tags.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AACpD,OAAO,EAAyB,iBAAiB,EAAE,MAAM,wBAAwB,CAAC;AAClF,OAAO,EAAE,WAAW,EAAE,MAAM,uCAAuC,CAAC;AACpE,OAAO,EAAE,qBAAqB,EAAE,MAAM,8BAA8B,CAAC;AACrE,OAAO,EAAE,kBAAkB,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAEhF,MAAM,UAAU,mBAAmB,CAAC,MAAiB;IACnD,MAAM,CAAC,YAAY,CACjB,cAAc,EACd;QACE,KAAK,EAAE,8BAA8B;QACrC,WAAW,EAAE;;;;;;;;;;;;sCAYmB;QAChC,WAAW,EAAE,iBAAiB;QAC9B,WAAW,EAAE;YACX,YAAY,EAAE,IAAI;YAClB,eAAe,EAAE,KAAK;YACtB,cAAc,EAAE,IAAI;YACpB,aAAa,EAAE,KAAK;SACrB;KACF,EACD,KAAK,EAAE,MAAwB,EAAE,EAAE;QACjC,IAAI,CAAC;YACH,MAAM,QAAQ,GAAG,MAAM,WAAW,CAAC,MAAM,CAAC,SAAS,CAAC,CAAC;YAErD,MAAM,GAAG,GACP,MAAM,CAAC,eAAe,KAAK,cAAc,CAAC,IAAI;gBAC5C,CAAC,CAAC,IAAI,CAAC,SAAS,CAAC,QAAQ,EAAE,IAAI,EAAE,CAAC,CAAC;gBACnC,CAAC,CAAC,kBAAkB,CAAC,QAAQ,CAAC,CAAC;YAEnC,MAAM,EAAE,IAAI,EAAE,GAAG,gBAAgB,CAAC,GAAG,CAAC,CAAC;YACvC,OAAO,EAAE,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAe,EAAE,IAAI,EAAE,CAAC,EAAE,CAAC;QACxD,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,MAAM,GAAG,GAAG,qBAAqB,CAAC,KAAK,CAAC,CAAC;YACzC,OAAO;gBACL,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAe,EAAE,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC,GAAG,EAAE,IAAI,EAAE,CAAC,CAAC,EAAE,CAAC;gBACxE,OAAO,EAAE,IAAI;aACd,CAAC;QACJ,CAAC;IACH,CAAC,CACF,CAAC;AACJ,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* locate_objects - object number → page and rectangle (Issue #20).
|
|
3
3
|
*/
|
|
4
|
-
import type { McpServer } from '@modelcontextprotocol/
|
|
4
|
+
import type { McpServer } from '@modelcontextprotocol/server';
|
|
5
5
|
export declare function registerLocateObjects(server: McpServer): void;
|
|
6
6
|
//# sourceMappingURL=locate-objects.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"locate-objects.d.ts","sourceRoot":"","sources":["../../../src/tools/tier2/locate-objects.ts"],"names":[],"mappings":"AAAA;;GAEG;
|
|
1
|
+
{"version":3,"file":"locate-objects.d.ts","sourceRoot":"","sources":["../../../src/tools/tier2/locate-objects.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,8BAA8B,CAAC;AAO9D,wBAAgB,qBAAqB,CAAC,MAAM,EAAE,SAAS,GAAG,IAAI,CAyD7D"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"locate-objects.js","sourceRoot":"","sources":["../../../src/tools/tier2/locate-objects.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"locate-objects.js","sourceRoot":"","sources":["../../../src/tools/tier2/locate-objects.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AACpD,OAAO,EAA2B,mBAAmB,EAAE,MAAM,wBAAwB,CAAC;AACtF,OAAO,EAAE,aAAa,EAAE,MAAM,kCAAkC,CAAC;AACjE,OAAO,EAAE,qBAAqB,EAAE,MAAM,8BAA8B,CAAC;AACrE,OAAO,EAAE,6BAA6B,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAE3F,MAAM,UAAU,qBAAqB,CAAC,MAAiB;IACrD,MAAM,CAAC,YAAY,CACjB,gBAAgB,EAChB;QACE,KAAK,EAAE,yDAAyD;QAChE,WAAW,EAAE;;;;;;;;;;;;;;;;;;;;;;;2EAuBwD;QACrE,WAAW,EAAE,mBAAmB;QAChC,WAAW,EAAE;YACX,YAAY,EAAE,IAAI;YAClB,eAAe,EAAE,KAAK;YACtB,cAAc,EAAE,IAAI;YACpB,aAAa,EAAE,KAAK;SACrB;KACF,EACD,KAAK,EAAE,MAA0B,EAAE,EAAE;QACnC,IAAI,CAAC;YACH,MAAM,MAAM,GAAG,MAAM,aAAa,CAAC,MAAM,CAAC,SAAS,EAAE,MAAM,CAAC,cAAc,CAAC,CAAC;YAE5E,MAAM,GAAG,GACP,MAAM,CAAC,eAAe,KAAK,cAAc,CAAC,IAAI;gBAC5C,CAAC,CAAC,IAAI,CAAC,SAAS,CAAC,MAAM,EAAE,IAAI,EAAE,CAAC,CAAC;gBACjC,CAAC,CAAC,6BAA6B,CAAC,MAAM,CAAC,CAAC;YAE5C,MAAM,EAAE,IAAI,EAAE,GAAG,gBAAgB,CAAC,GAAG,CAAC,CAAC;YACvC,OAAO,EAAE,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAe,EAAE,IAAI,EAAE,CAAC,EAAE,CAAC;QACxD,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,MAAM,GAAG,GAAG,qBAAqB,CAAC,KAAK,CAAC,CAAC;YACzC,OAAO;gBACL,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAe,EAAE,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC,GAAG,EAAE,IAAI,EAAE,CAAC,CAAC,EAAE,CAAC;gBACxE,OAAO,EAAE,IAAI;aACd,CAAC;QACJ,CAAC;IACH,CAAC,CACF,CAAC;AACJ,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* compare_structure - Compare structures of two PDF documents.
|
|
3
3
|
*/
|
|
4
|
-
import type { McpServer } from '@modelcontextprotocol/
|
|
4
|
+
import type { McpServer } from '@modelcontextprotocol/server';
|
|
5
5
|
export declare function registerCompareStructure(server: McpServer): void;
|
|
6
6
|
//# sourceMappingURL=compare-structure.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"compare-structure.d.ts","sourceRoot":"","sources":["../../../src/tools/tier3/compare-structure.ts"],"names":[],"mappings":"AAAA;;GAEG;
|
|
1
|
+
{"version":3,"file":"compare-structure.d.ts","sourceRoot":"","sources":["../../../src/tools/tier3/compare-structure.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,8BAA8B,CAAC;AAO9D,wBAAgB,wBAAwB,CAAC,MAAM,EAAE,SAAS,GAAG,IAAI,CAiDhE"}
|
|
@@ -1,6 +1,3 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* compare_structure - Compare structures of two PDF documents.
|
|
3
|
-
*/
|
|
4
1
|
import { ResponseFormat } from '../../constants.js';
|
|
5
2
|
import { CompareStructureSchema } from '../../schemas/tier3.js';
|
|
6
3
|
import { compareStructure } from '../../services/validation-service.js';
|
|
@@ -19,6 +16,8 @@ Args:
|
|
|
19
16
|
Returns:
|
|
20
17
|
Structural comparison including: property-by-property diff (page count, PDF version, encryption, tagged status, object counts, page dimensions, file size, catalog entries, signatures), font comparison (fonts unique to each file and shared fonts), and a summary.
|
|
21
18
|
|
|
19
|
+
The comparison needs both files, so an unreadable file is an error — but the error names which of the two could not be read, and says that the other one was fine.
|
|
20
|
+
|
|
22
21
|
Examples:
|
|
23
22
|
- Compare two versions of the same document
|
|
24
23
|
- Verify structural consistency across PDF exports
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"compare-structure.js","sourceRoot":"","sources":["../../../src/tools/tier3/compare-structure.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"compare-structure.js","sourceRoot":"","sources":["../../../src/tools/tier3/compare-structure.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AACpD,OAAO,EAA8B,sBAAsB,EAAE,MAAM,wBAAwB,CAAC;AAC5F,OAAO,EAAE,gBAAgB,EAAE,MAAM,sCAAsC,CAAC;AACxE,OAAO,EAAE,qBAAqB,EAAE,MAAM,8BAA8B,CAAC;AACrE,OAAO,EAAE,8BAA8B,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAE5F,MAAM,UAAU,wBAAwB,CAAC,MAAiB;IACxD,MAAM,CAAC,YAAY,CACjB,mBAAmB,EACnB;QACE,KAAK,EAAE,wBAAwB;QAC/B,WAAW,EAAE;;;;;;;;;;;;;;;qDAekC;QAC/C,WAAW,EAAE,sBAAsB;QACnC,WAAW,EAAE;YACX,YAAY,EAAE,IAAI;YAClB,eAAe,EAAE,KAAK;YACtB,cAAc,EAAE,IAAI;YACpB,aAAa,EAAE,KAAK;SACrB;KACF,EACD,KAAK,EAAE,MAA6B,EAAE,EAAE;QACtC,IAAI,CAAC;YACH,MAAM,MAAM,GAAG,MAAM,gBAAgB,CAAC,MAAM,CAAC,WAAW,EAAE,MAAM,CAAC,WAAW,CAAC,CAAC;YAE9E,MAAM,GAAG,GACP,MAAM,CAAC,eAAe,KAAK,cAAc,CAAC,IAAI;gBAC5C,CAAC,CAAC,IAAI,CAAC,SAAS,CAAC,MAAM,EAAE,IAAI,EAAE,CAAC,CAAC;gBACjC,CAAC,CAAC,8BAA8B,CAAC,MAAM,CAAC,CAAC;YAE7C,MAAM,EAAE,IAAI,EAAE,GAAG,gBAAgB,CAAC,GAAG,CAAC,CAAC;YACvC,OAAO,EAAE,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAe,EAAE,IAAI,EAAE,CAAC,EAAE,CAAC;QACxD,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,MAAM,GAAG,GAAG,qBAAqB,CAAC,KAAK,CAAC,CAAC;YACzC,OAAO;gBACL,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAe,EAAE,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC,GAAG,EAAE,IAAI,EAAE,CAAC,CAAC,EAAE,CAAC;gBACxE,OAAO,EAAE,IAAI;aACd,CAAC;QACJ,CAAC;IACH,CAAC,CACF,CAAC;AACJ,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* validate_metadata - PDF metadata conformance validation.
|
|
3
3
|
*/
|
|
4
|
-
import type { McpServer } from '@modelcontextprotocol/
|
|
4
|
+
import type { McpServer } from '@modelcontextprotocol/server';
|
|
5
5
|
export declare function registerValidateMetadata(server: McpServer): void;
|
|
6
6
|
//# sourceMappingURL=validate-metadata.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"validate-metadata.d.ts","sourceRoot":"","sources":["../../../src/tools/tier3/validate-metadata.ts"],"names":[],"mappings":"AAAA;;GAEG;
|
|
1
|
+
{"version":3,"file":"validate-metadata.d.ts","sourceRoot":"","sources":["../../../src/tools/tier3/validate-metadata.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,8BAA8B,CAAC;AAO9D,wBAAgB,wBAAwB,CAAC,MAAM,EAAE,SAAS,GAAG,IAAI,CAwEhE"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"validate-metadata.js","sourceRoot":"","sources":["../../../src/tools/tier3/validate-metadata.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"validate-metadata.js","sourceRoot":"","sources":["../../../src/tools/tier3/validate-metadata.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AACpD,OAAO,EAA8B,sBAAsB,EAAE,MAAM,wBAAwB,CAAC;AAC5F,OAAO,EAAE,gBAAgB,EAAE,MAAM,sCAAsC,CAAC;AACxE,OAAO,EAAE,qBAAqB,EAAE,MAAM,8BAA8B,CAAC;AACrE,OAAO,EAAE,gCAAgC,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAE9F,MAAM,UAAU,wBAAwB,CAAC,MAAiB;IACxD,MAAM,CAAC,YAAY,CACjB,mBAAmB,EACnB;QACE,KAAK,EAAE,oCAAoC;QAC3C,WAAW,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;+FAsC4E;QACzF,WAAW,EAAE,sBAAsB;QACnC,WAAW,EAAE;YACX,YAAY,EAAE,IAAI;YAClB,eAAe,EAAE,KAAK;YACtB,cAAc,EAAE,IAAI;YACpB,aAAa,EAAE,KAAK;SACrB;KACF,EACD,KAAK,EAAE,MAA6B,EAAE,EAAE;QACtC,IAAI,CAAC;YACH,MAAM,MAAM,GAAG,MAAM,gBAAgB,CAAC,MAAM,CAAC,SAAS,CAAC,CAAC;YAExD,MAAM,GAAG,GACP,MAAM,CAAC,eAAe,KAAK,cAAc,CAAC,IAAI;gBAC5C,CAAC,CAAC,IAAI,CAAC,SAAS,CAAC,MAAM,EAAE,IAAI,EAAE,CAAC,CAAC;gBACjC,CAAC,CAAC,gCAAgC,CAAC,MAAM,CAAC,CAAC;YAE/C,MAAM,EAAE,IAAI,EAAE,GAAG,gBAAgB,CAAC,GAAG,CAAC,CAAC;YACvC,OAAO,EAAE,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAe,EAAE,IAAI,EAAE,CAAC,EAAE,CAAC;QACxD,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,MAAM,GAAG,GAAG,qBAAqB,CAAC,KAAK,CAAC,CAAC;YACzC,OAAO;gBACL,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAe,EAAE,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC,GAAG,EAAE,IAAI,EAAE,CAAC,CAAC,EAAE,CAAC;gBACxE,OAAO,EAAE,IAAI;aACd,CAAC;QACJ,CAAC;IACH,CAAC,CACF,CAAC;AACJ,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* validate_tagged - PDF/UA tagged structure validation.
|
|
3
3
|
*/
|
|
4
|
-
import type { McpServer } from '@modelcontextprotocol/
|
|
4
|
+
import type { McpServer } from '@modelcontextprotocol/server';
|
|
5
5
|
export declare function registerValidateTagged(server: McpServer): void;
|
|
6
6
|
//# sourceMappingURL=validate-tagged.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"validate-tagged.d.ts","sourceRoot":"","sources":["../../../src/tools/tier3/validate-tagged.ts"],"names":[],"mappings":"AAAA;;GAEG;
|
|
1
|
+
{"version":3,"file":"validate-tagged.d.ts","sourceRoot":"","sources":["../../../src/tools/tier3/validate-tagged.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,8BAA8B,CAAC;AAO9D,wBAAgB,sBAAsB,CAAC,MAAM,EAAE,SAAS,GAAG,IAAI,CAyE9D"}
|
|
@@ -1,6 +1,3 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* validate_tagged - PDF/UA tagged structure validation.
|
|
3
|
-
*/
|
|
4
1
|
import { ResponseFormat } from '../../constants.js';
|
|
5
2
|
import { ValidateTaggedSchema } from '../../schemas/tier3.js';
|
|
6
3
|
import { validateTagged } from '../../services/validation-service.js';
|
|
@@ -33,6 +30,8 @@ Args:
|
|
|
33
30
|
Returns:
|
|
34
31
|
Validation results including: whether the PDF is tagged, total checks performed, pass/fail counts, detailed issues with severity levels (error/warning/info), and a summary.
|
|
35
32
|
|
|
33
|
+
\`totalChecks\` counts the checks that were actually decided. A check whose premise could not be observed is not counted there and appears in \`notChecked\` with the reason — TAG-005 judges Figure tags against the number of images the page draws, so without that number it would have to assume zero images and would report a pass for something nobody looked at.
|
|
34
|
+
|
|
36
35
|
Checks performed:
|
|
37
36
|
- Document marked as tagged
|
|
38
37
|
- Structure tree root existence
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"validate-tagged.js","sourceRoot":"","sources":["../../../src/tools/tier3/validate-tagged.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"validate-tagged.js","sourceRoot":"","sources":["../../../src/tools/tier3/validate-tagged.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AACpD,OAAO,EAA4B,oBAAoB,EAAE,MAAM,wBAAwB,CAAC;AACxF,OAAO,EAAE,cAAc,EAAE,MAAM,sCAAsC,CAAC;AACtE,OAAO,EAAE,qBAAqB,EAAE,MAAM,8BAA8B,CAAC;AACrE,OAAO,EAAE,8BAA8B,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAE5F,MAAM,UAAU,sBAAsB,CAAC,MAAiB;IACtD,MAAM,CAAC,YAAY,CACjB,iBAAiB,EACjB;QACE,KAAK,EAAE,kCAAkC;QACzC,WAAW,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;0CAuCuB;QACpC,WAAW,EAAE,oBAAoB;QACjC,WAAW,EAAE;YACX,YAAY,EAAE,IAAI;YAClB,eAAe,EAAE,KAAK;YACtB,cAAc,EAAE,IAAI;YACpB,aAAa,EAAE,KAAK;SACrB;KACF,EACD,KAAK,EAAE,MAA2B,EAAE,EAAE;QACpC,IAAI,CAAC;YACH,MAAM,MAAM,GAAG,MAAM,cAAc,CAAC,MAAM,CAAC,SAAS,CAAC,CAAC;YAEtD,MAAM,GAAG,GACP,MAAM,CAAC,eAAe,KAAK,cAAc,CAAC,IAAI;gBAC5C,CAAC,CAAC,IAAI,CAAC,SAAS,CAAC,MAAM,EAAE,IAAI,EAAE,CAAC,CAAC;gBACjC,CAAC,CAAC,8BAA8B,CAAC,MAAM,CAAC,CAAC;YAE7C,MAAM,EAAE,IAAI,EAAE,GAAG,gBAAgB,CAAC,GAAG,CAAC,CAAC;YACvC,OAAO,EAAE,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAe,EAAE,IAAI,EAAE,CAAC,EAAE,CAAC;QACxD,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,MAAM,GAAG,GAAG,qBAAqB,CAAC,KAAK,CAAC,CAAC;YACzC,OAAO;gBACL,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAe,EAAE,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC,GAAG,EAAE,IAAI,EAAE,CAAC,CAAC,EAAE,CAAC;gBACxE,OAAO,EAAE,IAAI;aACd,CAAC;QACJ,CAAC;IACH,CAAC,CACF,CAAC;AACJ,CAAC"}
|
package/dist/types.d.ts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* pdf-reader-mcp shared type definitions
|
|
3
3
|
*/
|
|
4
|
+
import type { ReadingScope, SummaryScope } from './services/reading-scope.js';
|
|
4
5
|
/** Metadata extracted from a PDF document */
|
|
5
6
|
export interface PdfMetadata {
|
|
6
7
|
title: string | null;
|
|
@@ -59,10 +60,22 @@ export interface PageExtractability {
|
|
|
59
60
|
/** A single page's extracted text */
|
|
60
61
|
export interface PageText {
|
|
61
62
|
page: number;
|
|
62
|
-
|
|
63
|
+
/**
|
|
64
|
+
* The text this server could take from the page.
|
|
65
|
+
*
|
|
66
|
+
* 🔴 `null` and `''` are different answers. `''` means the extraction ran and
|
|
67
|
+
* produced no characters; `null` means the extraction did not run on this
|
|
68
|
+
* document at all, and `ReadingScope.textExtraction` says why. Writing `''`
|
|
69
|
+
* for the second case would say "this page has no text", which is a claim
|
|
70
|
+
* this server did not measure.
|
|
71
|
+
*/
|
|
72
|
+
text: string | null;
|
|
63
73
|
/**
|
|
64
74
|
* Present when the caller asked for it (#21). Absent is not "extracted" —
|
|
65
|
-
* it means the state was not
|
|
75
|
+
* it means the state was not observed on this path. When the observation
|
|
76
|
+
* could not run at all, `ReadingScope.extractabilityObservation` says why;
|
|
77
|
+
* this field is left off rather than filled with zeros, because `0` fonts
|
|
78
|
+
* observed and "not observed" are different answers.
|
|
66
79
|
*/
|
|
67
80
|
extractability?: PageExtractability;
|
|
68
81
|
}
|
|
@@ -76,10 +89,18 @@ export interface SearchMatch {
|
|
|
76
89
|
}
|
|
77
90
|
/** Search results response */
|
|
78
91
|
export interface SearchResult {
|
|
92
|
+
/** どこまで読んだか。検索と観測は別々に失敗しうる。 */
|
|
93
|
+
scope?: ReadingScope;
|
|
79
94
|
query: string;
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
95
|
+
/**
|
|
96
|
+
* 見つかった件数。
|
|
97
|
+
*
|
|
98
|
+
* 🔴 `null` は 0 ではない。0 は「探して見つからなかった」、`null` は
|
|
99
|
+
* 「探せなかった」で、理由は `scope.textExtraction` にある。
|
|
100
|
+
*/
|
|
101
|
+
totalMatches: number | null;
|
|
102
|
+
matches: SearchMatch[] | null;
|
|
103
|
+
truncated: boolean | null;
|
|
83
104
|
/**
|
|
84
105
|
* Set when the search found nothing but the document is tagged (#15).
|
|
85
106
|
* search_text sees raw glyphs only — a tagged document may carry the
|
|
@@ -146,17 +167,23 @@ export interface ImageExtractionResult {
|
|
|
146
167
|
/** Summary report of a PDF document */
|
|
147
168
|
export interface PdfSummary {
|
|
148
169
|
filePath: string;
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
170
|
+
/**
|
|
171
|
+
* どこまで読んだか。この 4 つは別々に失敗しうる(#26)。
|
|
172
|
+
* 🔴 下の項目が `null` のときは、その読みが行われなかったということで、
|
|
173
|
+
* 「0 だった」「無かった」ではない。理由はここにある。
|
|
174
|
+
*/
|
|
175
|
+
scope?: SummaryScope;
|
|
176
|
+
metadata: PdfMetadata | null;
|
|
177
|
+
textPreview: string | null;
|
|
178
|
+
imageCount: number | null;
|
|
179
|
+
hasText: boolean | null;
|
|
153
180
|
/**
|
|
154
181
|
* Document-level fold of the per-page states (#21). `hasText` alone cannot
|
|
155
182
|
* say why text is absent; this can.
|
|
156
183
|
*/
|
|
157
|
-
textExtractability: TextExtractabilityState;
|
|
184
|
+
textExtractability: TextExtractabilityState | null;
|
|
158
185
|
/** The pages that are not `extracted`, so the caller can go straight to them. */
|
|
159
|
-
unreadablePages: PageExtractability[];
|
|
186
|
+
unreadablePages: PageExtractability[] | null;
|
|
160
187
|
/**
|
|
161
188
|
* What to call next, decided from the observations above (#24).
|
|
162
189
|
*
|
|
@@ -295,9 +322,15 @@ export interface ElementBox {
|
|
|
295
322
|
}
|
|
296
323
|
/** extract_structured_text output */
|
|
297
324
|
export interface StructuredTextResult {
|
|
298
|
-
|
|
325
|
+
/** どこまで読んだか。構造木の読み取りと §9.10.1 の観測は別々に失敗しうる。 */
|
|
326
|
+
scope?: ReadingScope;
|
|
327
|
+
/**
|
|
328
|
+
* 🔴 `null` は false ではない。false は「タグが無いと観測した」、`null` は
|
|
329
|
+
* 「構造木を読めなかった」で、理由は `scope.textExtraction` にある。
|
|
330
|
+
*/
|
|
331
|
+
isTagged: boolean | null;
|
|
299
332
|
lang: string | null;
|
|
300
|
-
elements: StructuredElement[];
|
|
333
|
+
elements: StructuredElement[] | null;
|
|
301
334
|
/**
|
|
302
335
|
* Per-page text extractability (#21). The structure tree says what the
|
|
303
336
|
* elements are; this says whether their characters could be read at all.
|
|
@@ -439,11 +472,21 @@ export interface ValidationIssue {
|
|
|
439
472
|
/** validate_tagged output */
|
|
440
473
|
export interface TaggedValidation {
|
|
441
474
|
isTagged: boolean;
|
|
475
|
+
/**
|
|
476
|
+
* 実際に判定できた検査の数。
|
|
477
|
+
* 🔴 前提を観測できずに回らなかった検査はここに入らない。`notChecked` にある。
|
|
478
|
+
* 回らなかった検査を「通った」に数えると、観測していないことが合格の顔をする。
|
|
479
|
+
*/
|
|
442
480
|
totalChecks: number;
|
|
443
481
|
passed: number;
|
|
444
482
|
failed: number;
|
|
445
483
|
warnings: number;
|
|
446
484
|
issues: ValidationIssue[];
|
|
485
|
+
/** 前提を観測できなかったので回らなかった検査。コードと、なぜ回らなかったか。 */
|
|
486
|
+
notChecked?: {
|
|
487
|
+
code: string;
|
|
488
|
+
reason: string;
|
|
489
|
+
}[];
|
|
447
490
|
summary: string;
|
|
448
491
|
}
|
|
449
492
|
/** validate_metadata output */
|