openlore 2.0.2 → 2.0.3

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.
Files changed (57) hide show
  1. package/README.md +28 -0
  2. package/dist/cli/commands/mcp.d.ts.map +1 -1
  3. package/dist/cli/commands/mcp.js +18 -1
  4. package/dist/cli/commands/mcp.js.map +1 -1
  5. package/dist/cli/export/index.d.ts +10 -0
  6. package/dist/cli/export/index.d.ts.map +1 -0
  7. package/dist/cli/export/index.js +27 -0
  8. package/dist/cli/export/index.js.map +1 -0
  9. package/dist/cli/export/scip.d.ts +22 -0
  10. package/dist/cli/export/scip.d.ts.map +1 -0
  11. package/dist/cli/export/scip.js +95 -0
  12. package/dist/cli/export/scip.js.map +1 -0
  13. package/dist/cli/index.js +4 -0
  14. package/dist/cli/index.js.map +1 -1
  15. package/dist/cli/manifest/detect/events.d.ts +31 -0
  16. package/dist/cli/manifest/detect/events.d.ts.map +1 -0
  17. package/dist/cli/manifest/detect/events.js +22 -0
  18. package/dist/cli/manifest/detect/events.js.map +1 -0
  19. package/dist/cli/manifest/detect/http-routes.d.ts +22 -0
  20. package/dist/cli/manifest/detect/http-routes.d.ts.map +1 -0
  21. package/dist/cli/manifest/detect/http-routes.js +18 -0
  22. package/dist/cli/manifest/detect/http-routes.js.map +1 -0
  23. package/dist/cli/manifest/detect/public-symbols.d.ts +46 -0
  24. package/dist/cli/manifest/detect/public-symbols.d.ts.map +1 -0
  25. package/dist/cli/manifest/detect/public-symbols.js +144 -0
  26. package/dist/cli/manifest/detect/public-symbols.js.map +1 -0
  27. package/dist/cli/manifest/emit.d.ts +103 -0
  28. package/dist/cli/manifest/emit.d.ts.map +1 -0
  29. package/dist/cli/manifest/emit.js +272 -0
  30. package/dist/cli/manifest/emit.js.map +1 -0
  31. package/dist/cli/manifest/index.d.ts +11 -0
  32. package/dist/cli/manifest/index.d.ts.map +1 -0
  33. package/dist/cli/manifest/index.js +31 -0
  34. package/dist/cli/manifest/index.js.map +1 -0
  35. package/dist/cli/manifest/schema-validator.d.ts +18 -0
  36. package/dist/cli/manifest/schema-validator.d.ts.map +1 -0
  37. package/dist/cli/manifest/schema-validator.js +77 -0
  38. package/dist/cli/manifest/schema-validator.js.map +1 -0
  39. package/dist/cli/manifest/validate.d.ts +15 -0
  40. package/dist/cli/manifest/validate.d.ts.map +1 -0
  41. package/dist/cli/manifest/validate.js +51 -0
  42. package/dist/cli/manifest/validate.js.map +1 -0
  43. package/dist/core/scip/index.d.ts +51 -0
  44. package/dist/core/scip/index.d.ts.map +1 -0
  45. package/dist/core/scip/index.js +210 -0
  46. package/dist/core/scip/index.js.map +1 -0
  47. package/dist/core/scip/moniker.d.ts +48 -0
  48. package/dist/core/scip/moniker.d.ts.map +1 -0
  49. package/dist/core/scip/moniker.js +109 -0
  50. package/dist/core/scip/moniker.js.map +1 -0
  51. package/dist/core/scip/schema.d.ts +34 -0
  52. package/dist/core/scip/schema.d.ts.map +1 -0
  53. package/dist/core/scip/schema.js +48 -0
  54. package/dist/core/scip/schema.js.map +1 -0
  55. package/dist/core/scip/vendor/scip.proto +910 -0
  56. package/package.json +3 -1
  57. package/schemas/openlore-manifest-v1.json +191 -0
@@ -0,0 +1,34 @@
1
+ /**
2
+ * Loads the vendored SCIP protobuf schema and exposes the `scip.Index` type.
3
+ *
4
+ * The schema is vendored verbatim at `vendor/scip.proto` (pinned — see the
5
+ * header comment in that file). We parse it at runtime with protobufjs (pure
6
+ * JS, no native build) rather than committing a generated `pb.js`, which keeps
7
+ * the vendored artifact human-readable and trivially re-fetchable.
8
+ */
9
+ import protobuf from 'protobufjs';
10
+ /** Absolute path to the vendored proto, resolved relative to this module. */
11
+ export declare function scipProtoPath(): string;
12
+ /** Parse the vendored proto and return the protobufjs Root. */
13
+ export declare function loadScipRoot(): protobuf.Root;
14
+ /** The `scip.Index` message type, used to verify + serialize an index payload. */
15
+ export declare function scipIndexType(): protobuf.Type;
16
+ /**
17
+ * SCIP `SymbolRole` bitset values we use. Mirrors the enum in scip.proto.
18
+ * Kept as a const object (not an import) because the proto enums are not
19
+ * surfaced as TS values by protobufjs's runtime parse.
20
+ */
21
+ export declare const SymbolRole: {
22
+ readonly Definition: 1;
23
+ readonly ReadAccess: 8;
24
+ };
25
+ /**
26
+ * SCIP `TextEncoding.UTF8`. The index declares source files are UTF-8 on disk.
27
+ */
28
+ export declare const TextEncoding_UTF8 = 1;
29
+ /**
30
+ * SCIP `SymbolInformation.Kind.Function`. Every node we export is a
31
+ * function/method, so we tag them uniformly.
32
+ */
33
+ export declare const SymbolKind_Function = 17;
34
+ //# sourceMappingURL=schema.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../../../src/core/scip/schema.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAIH,OAAO,QAAQ,MAAM,YAAY,CAAC;AAKlC,6EAA6E;AAC7E,wBAAgB,aAAa,IAAI,MAAM,CAEtC;AAED,+DAA+D;AAC/D,wBAAgB,YAAY,IAAI,QAAQ,CAAC,IAAI,CAK5C;AAED,kFAAkF;AAClF,wBAAgB,aAAa,IAAI,QAAQ,CAAC,IAAI,CAE7C;AAED;;;;GAIG;AACH,eAAO,MAAM,UAAU;;;CAGb,CAAC;AAEX;;GAEG;AACH,eAAO,MAAM,iBAAiB,IAAI,CAAC;AAEnC;;;GAGG;AACH,eAAO,MAAM,mBAAmB,KAAK,CAAC"}
@@ -0,0 +1,48 @@
1
+ /**
2
+ * Loads the vendored SCIP protobuf schema and exposes the `scip.Index` type.
3
+ *
4
+ * The schema is vendored verbatim at `vendor/scip.proto` (pinned — see the
5
+ * header comment in that file). We parse it at runtime with protobufjs (pure
6
+ * JS, no native build) rather than committing a generated `pb.js`, which keeps
7
+ * the vendored artifact human-readable and trivially re-fetchable.
8
+ */
9
+ import { readFileSync } from 'node:fs';
10
+ import { fileURLToPath } from 'node:url';
11
+ import protobuf from 'protobufjs';
12
+ /** Resolved once and memoized — parsing the proto is cheap but not free. */
13
+ let cachedRoot;
14
+ /** Absolute path to the vendored proto, resolved relative to this module. */
15
+ export function scipProtoPath() {
16
+ return fileURLToPath(new URL('./vendor/scip.proto', import.meta.url));
17
+ }
18
+ /** Parse the vendored proto and return the protobufjs Root. */
19
+ export function loadScipRoot() {
20
+ if (cachedRoot)
21
+ return cachedRoot;
22
+ const protoText = readFileSync(scipProtoPath(), 'utf-8');
23
+ cachedRoot = protobuf.parse(protoText, { keepCase: true }).root;
24
+ return cachedRoot;
25
+ }
26
+ /** The `scip.Index` message type, used to verify + serialize an index payload. */
27
+ export function scipIndexType() {
28
+ return loadScipRoot().lookupType('scip.Index');
29
+ }
30
+ /**
31
+ * SCIP `SymbolRole` bitset values we use. Mirrors the enum in scip.proto.
32
+ * Kept as a const object (not an import) because the proto enums are not
33
+ * surfaced as TS values by protobufjs's runtime parse.
34
+ */
35
+ export const SymbolRole = {
36
+ Definition: 0x1,
37
+ ReadAccess: 0x8,
38
+ };
39
+ /**
40
+ * SCIP `TextEncoding.UTF8`. The index declares source files are UTF-8 on disk.
41
+ */
42
+ export const TextEncoding_UTF8 = 1;
43
+ /**
44
+ * SCIP `SymbolInformation.Kind.Function`. Every node we export is a
45
+ * function/method, so we tag them uniformly.
46
+ */
47
+ export const SymbolKind_Function = 17;
48
+ //# sourceMappingURL=schema.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"schema.js","sourceRoot":"","sources":["../../../src/core/scip/schema.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AACvC,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AACzC,OAAO,QAAQ,MAAM,YAAY,CAAC;AAElC,4EAA4E;AAC5E,IAAI,UAAqC,CAAC;AAE1C,6EAA6E;AAC7E,MAAM,UAAU,aAAa;IAC3B,OAAO,aAAa,CAAC,IAAI,GAAG,CAAC,qBAAqB,EAAE,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC;AACxE,CAAC;AAED,+DAA+D;AAC/D,MAAM,UAAU,YAAY;IAC1B,IAAI,UAAU;QAAE,OAAO,UAAU,CAAC;IAClC,MAAM,SAAS,GAAG,YAAY,CAAC,aAAa,EAAE,EAAE,OAAO,CAAC,CAAC;IACzD,UAAU,GAAG,QAAQ,CAAC,KAAK,CAAC,SAAS,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,CAAC,IAAI,CAAC;IAChE,OAAO,UAAU,CAAC;AACpB,CAAC;AAED,kFAAkF;AAClF,MAAM,UAAU,aAAa;IAC3B,OAAO,YAAY,EAAE,CAAC,UAAU,CAAC,YAAY,CAAC,CAAC;AACjD,CAAC;AAED;;;;GAIG;AACH,MAAM,CAAC,MAAM,UAAU,GAAG;IACxB,UAAU,EAAE,GAAG;IACf,UAAU,EAAE,GAAG;CACP,CAAC;AAEX;;GAEG;AACH,MAAM,CAAC,MAAM,iBAAiB,GAAG,CAAC,CAAC;AAEnC;;;GAGG;AACH,MAAM,CAAC,MAAM,mBAAmB,GAAG,EAAE,CAAC"}