@nakafa/aksara-contracts 0.35.0 → 0.37.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.
@@ -1,52 +1,30 @@
1
1
  import { Schema } from "effect";
2
- import { type ContentFamily } from "#contracts/content";
3
- import { type ReleaseId, type Sha256Hash } from "#contracts/ids";
4
- /** Global content-runtime tag always invalidated before narrower tags. */
5
- export declare const CONTENT_CACHE_GLOBAL_TAG = "content-runtime";
6
- /** Maximum exact artifact tags carried with global and family cache tags. */
7
- export declare const MAX_CONTENT_CACHE_ARTIFACTS = 98;
2
+ import { type Sha256Hash } from "#contracts/ids";
3
+ /** Mutable publication dependencies owned by the signed source contracts. */
4
+ export declare const ContentCacheScopeSchema: Schema.Literals<readonly ["article", "material", "page", "question", "program", "quran", "tryout"]>;
5
+ export type ContentCacheScope = typeof ContentCacheScopeSchema.Type;
8
6
  /** One immutable published-artifact cache tag derived only from its hash. */
9
7
  export declare const ArtifactCacheTagSchema: Schema.brand<Schema.String, "@NakafaAI/AksaraArtifactCacheTag">;
10
8
  export type ArtifactCacheTag = typeof ArtifactCacheTagSchema.Type;
11
- /** One exact content-family cache tag derived from the family contract. */
12
- export declare const ContentFamilyCacheTagSchema: Schema.brand<Schema.String, "@NakafaAI/AksaraContentFamilyCacheTag">;
13
- export type ContentFamilyCacheTag = typeof ContentFamilyCacheTagSchema.Type;
14
- /**
15
- * Ordered cache tags shared by Aksara and Nakafa.
16
- *
17
- * Global and exact family tags come first; remaining tags name exact changed
18
- * artifacts while keeping one invalidation request at or below 100 tags.
19
- */
20
- export declare const ContentCacheTagsSchema: Schema.TupleWithRest<Schema.Tuple<readonly [Schema.Literal<"content-runtime">, Schema.brand<Schema.String, "@NakafaAI/AksaraContentFamilyCacheTag">]>, readonly [Schema.brand<Schema.String, "@NakafaAI/AksaraArtifactCacheTag">]>;
21
- export type ContentCacheTags = typeof ContentCacheTagsSchema.Type;
22
- /** One changed family plus its optional newly published immutable artifact. */
9
+ /** A changed item or snapshot invalidates its mutable selection dependency. */
23
10
  export declare const ContentCacheChangeSchema: Schema.Struct<{
24
- readonly artifactHash: Schema.optional<Schema.brand<Schema.String, "@NakafaAI/AksaraSha256Hash">>;
25
- readonly family: Schema.Literals<readonly ["article", "material", "page", "question"]>;
11
+ readonly scope: Schema.Literals<readonly ["article", "material", "page", "question", "program", "quran", "tryout"]>;
26
12
  }>;
27
13
  export type ContentCacheChange = typeof ContentCacheChangeSchema.Type;
28
- /** Derives the canonical cache tag for one already-canonical artifact hash. */
29
- export declare function makeArtifactCacheTag(hash: Sha256Hash): ArtifactCacheTag;
30
- /** Derives the canonical cache tag for one implemented content family. */
31
- export declare function makeContentFamilyCacheTag(family: ContentFamily): ContentFamilyCacheTag;
32
- /** One release-bound, family-exact cache invalidation request. */
14
+ /** One release-bound invalidation cannot name global or immutable cache tags. */
33
15
  export declare const ContentCacheRequestSchema: Schema.Struct<{
34
- readonly family: Schema.Literals<readonly ["article", "material", "page", "question"]>;
35
16
  readonly releaseId: Schema.brand<Schema.String, "@NakafaAI/AksaraReleaseId">;
36
- readonly tags: Schema.TupleWithRest<Schema.Tuple<readonly [Schema.Literal<"content-runtime">, Schema.brand<Schema.String, "@NakafaAI/AksaraContentFamilyCacheTag">]>, readonly [Schema.brand<Schema.String, "@NakafaAI/AksaraArtifactCacheTag">]>;
17
+ readonly scope: Schema.Literals<readonly ["article", "material", "page", "question", "program", "quran", "tryout"]>;
37
18
  }>;
38
19
  export type ContentCacheRequest = typeof ContentCacheRequestSchema.Type;
39
- /** Nakafa proof that one exact release-bound invalidation completed. */
20
+ /** Nakafa proof that one exact release-bound dependency was invalidated. */
40
21
  export declare const ContentCacheReceiptSchema: Schema.Struct<{
41
- readonly family: Schema.Literals<readonly ["article", "material", "page", "question"]>;
42
22
  readonly releaseId: Schema.brand<Schema.String, "@NakafaAI/AksaraReleaseId">;
23
+ readonly scope: Schema.Literals<readonly ["article", "material", "page", "question", "program", "quran", "tryout"]>;
43
24
  readonly revalidated: Schema.Literal<true>;
44
- readonly tags: Schema.TupleWithRest<Schema.Tuple<readonly [Schema.Literal<"content-runtime">, Schema.brand<Schema.String, "@NakafaAI/AksaraContentFamilyCacheTag">]>, readonly [Schema.brand<Schema.String, "@NakafaAI/AksaraArtifactCacheTag">]>;
45
25
  }>;
46
26
  export type ContentCacheReceipt = typeof ContentCacheReceiptSchema.Type;
47
- /** Builds one ordered invalidation request for one exact content family. */
48
- export declare function makeContentCacheRequest(input: {
49
- readonly artifactHashes: readonly Sha256Hash[];
50
- readonly family: ContentFamily;
51
- readonly releaseId: ReleaseId;
52
- }): ContentCacheRequest;
27
+ /** Derives the canonical cache tag for one already-canonical artifact hash. */
28
+ export declare function makeArtifactCacheTag(hash: Sha256Hash): ArtifactCacheTag;
29
+ /** Derives the same mutable dependency tag in the reader and invalidator. */
30
+ export declare function makeContentCacheTag(scope: ContentCacheScope): string;
@@ -1,80 +1,38 @@
1
1
  import { Schema } from "effect";
2
2
  import { ContentFamilySchema } from "#contracts/content";
3
3
  import { ReleaseIdSchema, Sha256HashSchema, } from "#contracts/ids";
4
- /** Global content-runtime tag always invalidated before narrower tags. */
5
- export const CONTENT_CACHE_GLOBAL_TAG = "content-runtime";
4
+ import { ContentSnapshotKindSchema } from "#contracts/release/snapshot/scope";
6
5
  const ARTIFACT_CACHE_PREFIX = "content-artifact:";
7
- const FAMILY_CACHE_PREFIX = "content-family:";
8
- /** Maximum exact artifact tags carried with global and family cache tags. */
9
- export const MAX_CONTENT_CACHE_ARTIFACTS = 98;
6
+ const SCOPE_CACHE_PREFIX = "content-scope:";
7
+ /** Mutable publication dependencies owned by the signed source contracts. */
8
+ export const ContentCacheScopeSchema = Schema.Literals([
9
+ ...ContentFamilySchema.literals,
10
+ ...ContentSnapshotKindSchema.literals,
11
+ ]);
10
12
  /** One immutable published-artifact cache tag derived only from its hash. */
11
13
  export const ArtifactCacheTagSchema = Schema.String.pipe(Schema.check(Schema.makeFilter((tag) => tag.startsWith(ARTIFACT_CACHE_PREFIX) &&
12
14
  Schema.is(Sha256HashSchema)(tag.slice(ARTIFACT_CACHE_PREFIX.length)), {
13
15
  message: "Expected content-artifact followed by one canonical SHA-256 hash.",
14
16
  })), Schema.brand("@NakafaAI/AksaraArtifactCacheTag"));
15
- /** One exact content-family cache tag derived from the family contract. */
16
- export const ContentFamilyCacheTagSchema = Schema.String.pipe(Schema.check(Schema.makeFilter((tag) => tag.startsWith(FAMILY_CACHE_PREFIX) &&
17
- Schema.is(ContentFamilySchema)(tag.slice(FAMILY_CACHE_PREFIX.length)), { message: "Expected one canonical content-family cache tag." })), Schema.brand("@NakafaAI/AksaraContentFamilyCacheTag"));
18
- /** Checks one cache request carries no redundant exact artifact tags. */
19
- function hasUniqueArtifactTags(tags) {
20
- const artifacts = tags.slice(2);
21
- return new Set(artifacts).size === artifacts.length;
22
- }
23
- /**
24
- * Ordered cache tags shared by Aksara and Nakafa.
25
- *
26
- * Global and exact family tags come first; remaining tags name exact changed
27
- * artifacts while keeping one invalidation request at or below 100 tags.
28
- */
29
- export const ContentCacheTagsSchema = Schema.TupleWithRest(Schema.Tuple([
30
- Schema.Literal(CONTENT_CACHE_GLOBAL_TAG),
31
- ContentFamilyCacheTagSchema,
32
- ]), [ArtifactCacheTagSchema]).pipe(Schema.check(Schema.isMaxLength(MAX_CONTENT_CACHE_ARTIFACTS + 2)), Schema.check(Schema.makeFilter(hasUniqueArtifactTags, {
33
- message: "Expected unique exact artifact cache tags.",
34
- })));
35
- /** One changed family plus its optional newly published immutable artifact. */
17
+ /** A changed item or snapshot invalidates its mutable selection dependency. */
36
18
  export const ContentCacheChangeSchema = Schema.Struct({
37
- artifactHash: Schema.optional(Sha256HashSchema),
38
- family: ContentFamilySchema,
19
+ scope: ContentCacheScopeSchema,
39
20
  });
40
- /** Derives the canonical cache tag for one already-canonical artifact hash. */
41
- export function makeArtifactCacheTag(hash) {
42
- return ArtifactCacheTagSchema.make(`${ARTIFACT_CACHE_PREFIX}${hash}`);
43
- }
44
- /** Derives the canonical cache tag for one implemented content family. */
45
- export function makeContentFamilyCacheTag(family) {
46
- return ContentFamilyCacheTagSchema.make(`${FAMILY_CACHE_PREFIX}${family}`);
47
- }
48
- /** Checks the explicit family and ordered family cache tag cannot disagree. */
49
- function hasCoherentFamily(input) {
50
- return input.tags[1] === makeContentFamilyCacheTag(input.family);
51
- }
52
- /** One release-bound, family-exact cache invalidation request. */
21
+ /** One release-bound invalidation cannot name global or immutable cache tags. */
53
22
  export const ContentCacheRequestSchema = Schema.Struct({
54
- family: ContentFamilySchema,
55
23
  releaseId: ReleaseIdSchema,
56
- tags: ContentCacheTagsSchema,
57
- }).pipe(Schema.check(Schema.makeFilter(hasCoherentFamily, {
58
- message: "Expected the cache family to match its ordered family tag.",
59
- })));
60
- /** Nakafa proof that one exact release-bound invalidation completed. */
24
+ scope: ContentCacheScopeSchema,
25
+ });
26
+ /** Nakafa proof that one exact release-bound dependency was invalidated. */
61
27
  export const ContentCacheReceiptSchema = Schema.Struct({
62
- family: ContentFamilySchema,
63
- releaseId: ReleaseIdSchema,
28
+ ...ContentCacheRequestSchema.fields,
64
29
  revalidated: Schema.Literal(true),
65
- tags: ContentCacheTagsSchema,
66
- }).pipe(Schema.check(Schema.makeFilter(hasCoherentFamily, {
67
- message: "Expected the cache family to match its ordered family tag.",
68
- })));
69
- /** Builds one ordered invalidation request for one exact content family. */
70
- export function makeContentCacheRequest(input) {
71
- return ContentCacheRequestSchema.make({
72
- family: input.family,
73
- releaseId: input.releaseId,
74
- tags: [
75
- CONTENT_CACHE_GLOBAL_TAG,
76
- makeContentFamilyCacheTag(input.family),
77
- ...input.artifactHashes.map(makeArtifactCacheTag),
78
- ],
79
- });
30
+ });
31
+ /** Derives the canonical cache tag for one already-canonical artifact hash. */
32
+ export function makeArtifactCacheTag(hash) {
33
+ return ArtifactCacheTagSchema.make(`${ARTIFACT_CACHE_PREFIX}${hash}`);
34
+ }
35
+ /** Derives the same mutable dependency tag in the reader and invalidator. */
36
+ export function makeContentCacheTag(scope) {
37
+ return `${SCOPE_CACHE_PREFIX}${scope}`;
80
38
  }
@@ -42,89 +42,6 @@ export interface VerifiedContentProjections {
42
42
  }
43
43
  /** Strictly decodes a replayable canonical content projection stream. */
44
44
  export declare function decodeContentProjections<E, R>(projections: Stream.Stream<unknown, E, R>): Stream.Stream<{
45
- readonly appLocale: ("de" | "en" | "id") & import("effect/Brand").Brand<"@NakafaAI/AksaraAppLocale">;
46
- readonly articleRouteSlug: string & import("effect/Brand").Brand<"@NakafaAI/AksaraArticleRouteSlug">;
47
- readonly articleSlug: string & import("effect/Brand").Brand<"@NakafaAI/AksaraArticleSlug">;
48
- readonly artifactLocale: ("de" | "en" | "id") & import("effect/Brand").Brand<"@NakafaAI/AksaraArtifactLocale">;
49
- readonly category: string & import("effect/Brand").Brand<"@NakafaAI/AksaraArticleCategory">;
50
- readonly categoryRouteSlug: string & import("effect/Brand").Brand<"@NakafaAI/AksaraArticleRouteSlug">;
51
- readonly contentKey: string & import("effect/Brand").Brand<"@NakafaAI/AksaraContentKey">;
52
- readonly graph: {
53
- readonly alignmentId: string;
54
- readonly assetId: string;
55
- readonly conceptId: string;
56
- readonly learningObjectId: string;
57
- readonly lensId: string;
58
- };
59
- readonly publicPath: string & import("effect/Brand").Brand<"@NakafaAI/AksaraPublicPath">;
60
- readonly categoryTitle: string;
61
- readonly kind: "article";
62
- readonly metadata: {
63
- readonly dateModified?: string;
64
- readonly datePublished: string;
65
- readonly authors: readonly {
66
- readonly name: string;
67
- }[];
68
- readonly description?: string | undefined;
69
- readonly title: string;
70
- };
71
- readonly official: boolean;
72
- readonly parentPath: string & import("effect/Brand").Brand<"@NakafaAI/AksaraPublicPath">;
73
- readonly references: readonly {
74
- readonly authors: string;
75
- readonly citation?: string | undefined;
76
- readonly details?: string | undefined;
77
- readonly publication?: string | undefined;
78
- readonly title: string;
79
- readonly url?: string | undefined;
80
- readonly year: number;
81
- }[];
82
- readonly sitemap: true;
83
- } | {
84
- readonly appLocale: ("de" | "en" | "id") & import("effect/Brand").Brand<"@NakafaAI/AksaraAppLocale">;
85
- readonly artifactLocale: ("de" | "en" | "id") & import("effect/Brand").Brand<"@NakafaAI/AksaraArtifactLocale">;
86
- readonly contentKey: string & import("effect/Brand").Brand<"@NakafaAI/AksaraContentKey">;
87
- readonly graph: {
88
- readonly alignmentId: string;
89
- readonly assetId: string;
90
- readonly conceptId: string;
91
- readonly learningObjectId: string;
92
- readonly lensId: string;
93
- };
94
- readonly materialKey: string & import("effect/Brand").Brand<"@NakafaAI/AksaraMaterialKey">;
95
- readonly order: number;
96
- readonly publicPath: string & import("effect/Brand").Brand<"@NakafaAI/AksaraPublicPath">;
97
- readonly sectionKey: string & import("effect/Brand").Brand<"@NakafaAI/AksaraMaterialSection">;
98
- readonly kind: "subject-lesson";
99
- readonly metadata: {
100
- readonly dateModified?: string;
101
- readonly datePublished: string;
102
- readonly authors: readonly {
103
- readonly name: string;
104
- }[];
105
- readonly description?: string | undefined;
106
- readonly subject?: string | undefined;
107
- readonly title: string;
108
- };
109
- readonly parentPath: string & import("effect/Brand").Brand<"@NakafaAI/AksaraPublicPath">;
110
- readonly sitemap: true;
111
- readonly topicTitle: string;
112
- } | {
113
- readonly appLocale: ("de" | "en" | "id") & import("effect/Brand").Brand<"@NakafaAI/AksaraAppLocale">;
114
- readonly artifactLocale: ("de" | "en" | "id") & import("effect/Brand").Brand<"@NakafaAI/AksaraArtifactLocale">;
115
- readonly contentKey: string & import("effect/Brand").Brand<"@NakafaAI/AksaraContentKey">;
116
- readonly pageKey: string & import("effect/Brand").Brand<"@NakafaAI/AksaraPageKey">;
117
- readonly publicPath: string & import("effect/Brand").Brand<"@NakafaAI/AksaraPublicPath">;
118
- readonly kind: "public-page";
119
- readonly metadata: {
120
- readonly dateModified?: string;
121
- readonly datePublished: string;
122
- readonly description: string;
123
- readonly title: string;
124
- };
125
- readonly sitemap: true;
126
- readonly sourcePath: string & import("effect/Brand").Brand<"@NakafaAI/AksaraCorpusSourcePath">;
127
- } | {
128
45
  readonly artifactLocale: ("de" | "en" | "id") & import("effect/Brand").Brand<"@NakafaAI/AksaraArtifactLocale">;
129
46
  readonly contentKey: string & import("effect/Brand").Brand<"@NakafaAI/AksaraContentKey">;
130
47
  readonly peerContentKey: string & import("effect/Brand").Brand<"@NakafaAI/AksaraContentKey">;
@@ -236,6 +153,89 @@ export declare function decodeContentProjections<E, R>(projections: Stream.Strea
236
153
  readonly date: string;
237
154
  readonly title: string;
238
155
  };
156
+ } | {
157
+ readonly appLocale: ("de" | "en" | "id") & import("effect/Brand").Brand<"@NakafaAI/AksaraAppLocale">;
158
+ readonly articleRouteSlug: string & import("effect/Brand").Brand<"@NakafaAI/AksaraArticleRouteSlug">;
159
+ readonly articleSlug: string & import("effect/Brand").Brand<"@NakafaAI/AksaraArticleSlug">;
160
+ readonly artifactLocale: ("de" | "en" | "id") & import("effect/Brand").Brand<"@NakafaAI/AksaraArtifactLocale">;
161
+ readonly category: string & import("effect/Brand").Brand<"@NakafaAI/AksaraArticleCategory">;
162
+ readonly categoryRouteSlug: string & import("effect/Brand").Brand<"@NakafaAI/AksaraArticleRouteSlug">;
163
+ readonly contentKey: string & import("effect/Brand").Brand<"@NakafaAI/AksaraContentKey">;
164
+ readonly graph: {
165
+ readonly alignmentId: string;
166
+ readonly assetId: string;
167
+ readonly conceptId: string;
168
+ readonly learningObjectId: string;
169
+ readonly lensId: string;
170
+ };
171
+ readonly publicPath: string & import("effect/Brand").Brand<"@NakafaAI/AksaraPublicPath">;
172
+ readonly categoryTitle: string;
173
+ readonly kind: "article";
174
+ readonly metadata: {
175
+ readonly dateModified?: string;
176
+ readonly datePublished: string;
177
+ readonly authors: readonly {
178
+ readonly name: string;
179
+ }[];
180
+ readonly description?: string | undefined;
181
+ readonly title: string;
182
+ };
183
+ readonly official: boolean;
184
+ readonly parentPath: string & import("effect/Brand").Brand<"@NakafaAI/AksaraPublicPath">;
185
+ readonly references: readonly {
186
+ readonly authors: string;
187
+ readonly citation?: string | undefined;
188
+ readonly details?: string | undefined;
189
+ readonly publication?: string | undefined;
190
+ readonly title: string;
191
+ readonly url?: string | undefined;
192
+ readonly year: number;
193
+ }[];
194
+ readonly sitemap: true;
195
+ } | {
196
+ readonly appLocale: ("de" | "en" | "id") & import("effect/Brand").Brand<"@NakafaAI/AksaraAppLocale">;
197
+ readonly artifactLocale: ("de" | "en" | "id") & import("effect/Brand").Brand<"@NakafaAI/AksaraArtifactLocale">;
198
+ readonly contentKey: string & import("effect/Brand").Brand<"@NakafaAI/AksaraContentKey">;
199
+ readonly graph: {
200
+ readonly alignmentId: string;
201
+ readonly assetId: string;
202
+ readonly conceptId: string;
203
+ readonly learningObjectId: string;
204
+ readonly lensId: string;
205
+ };
206
+ readonly materialKey: string & import("effect/Brand").Brand<"@NakafaAI/AksaraMaterialKey">;
207
+ readonly order: number;
208
+ readonly publicPath: string & import("effect/Brand").Brand<"@NakafaAI/AksaraPublicPath">;
209
+ readonly sectionKey: string & import("effect/Brand").Brand<"@NakafaAI/AksaraMaterialSection">;
210
+ readonly kind: "subject-lesson";
211
+ readonly metadata: {
212
+ readonly dateModified?: string;
213
+ readonly datePublished: string;
214
+ readonly authors: readonly {
215
+ readonly name: string;
216
+ }[];
217
+ readonly description?: string | undefined;
218
+ readonly subject?: string | undefined;
219
+ readonly title: string;
220
+ };
221
+ readonly parentPath: string & import("effect/Brand").Brand<"@NakafaAI/AksaraPublicPath">;
222
+ readonly sitemap: true;
223
+ readonly topicTitle: string;
224
+ } | {
225
+ readonly appLocale: ("de" | "en" | "id") & import("effect/Brand").Brand<"@NakafaAI/AksaraAppLocale">;
226
+ readonly artifactLocale: ("de" | "en" | "id") & import("effect/Brand").Brand<"@NakafaAI/AksaraArtifactLocale">;
227
+ readonly contentKey: string & import("effect/Brand").Brand<"@NakafaAI/AksaraContentKey">;
228
+ readonly pageKey: string & import("effect/Brand").Brand<"@NakafaAI/AksaraPageKey">;
229
+ readonly publicPath: string & import("effect/Brand").Brand<"@NakafaAI/AksaraPublicPath">;
230
+ readonly kind: "public-page";
231
+ readonly metadata: {
232
+ readonly dateModified?: string;
233
+ readonly datePublished: string;
234
+ readonly description: string;
235
+ readonly title: string;
236
+ };
237
+ readonly sitemap: true;
238
+ readonly sourcePath: string & import("effect/Brand").Brand<"@NakafaAI/AksaraCorpusSourcePath">;
239
239
  }, E | ProjectionDecodeError | ProjectionOrderError | ProjectionRouteError, R>;
240
240
  /** Authenticates a replayable projection stream against its signed manifest. */
241
241
  export declare const verifyContentProjections: <E, R>(input: {
@@ -447,15 +447,16 @@ export declare function decodeContentSnapshotRows<E, R>(rows: Stream.Stream<unkn
447
447
  readonly title: string;
448
448
  readonly countryKey: string;
449
449
  readonly examKey: string;
450
- readonly kind: "track";
450
+ readonly kind: "section";
451
451
  readonly order: number;
452
- readonly publicPath: string & import("effect/Brand").Brand<"@NakafaAI/AksaraPublicPath">;
452
+ readonly publicPath?: (string & import("effect/Brand").Brand<"@NakafaAI/AksaraPublicPath">) | undefined;
453
453
  readonly questionCount: number;
454
- readonly sectionCount: number;
455
- readonly setCount: number;
454
+ readonly questionSourcePath: string & import("effect/Brand").Brand<"@NakafaAI/AksaraCorpusSourcePath">;
455
+ readonly sectionKey: string;
456
+ readonly setKey: string;
457
+ readonly timeLimitSeconds: number;
456
458
  readonly trackKey: string;
457
- readonly trackKind: "subject" | "year";
458
- readonly visibleSectionCount: number;
459
+ readonly visibility: "internal-entry" | "visible";
459
460
  } | {
460
461
  readonly appLocale: ("de" | "en" | "id") & import("effect/Brand").Brand<"@NakafaAI/AksaraAppLocale">;
461
462
  readonly description?: string | undefined;
@@ -494,16 +495,15 @@ export declare function decodeContentSnapshotRows<E, R>(rows: Stream.Stream<unkn
494
495
  readonly title: string;
495
496
  readonly countryKey: string;
496
497
  readonly examKey: string;
497
- readonly kind: "section";
498
+ readonly kind: "track";
498
499
  readonly order: number;
499
- readonly publicPath?: (string & import("effect/Brand").Brand<"@NakafaAI/AksaraPublicPath">) | undefined;
500
+ readonly publicPath: string & import("effect/Brand").Brand<"@NakafaAI/AksaraPublicPath">;
500
501
  readonly questionCount: number;
501
- readonly questionSourcePath: string & import("effect/Brand").Brand<"@NakafaAI/AksaraCorpusSourcePath">;
502
- readonly sectionKey: string;
503
- readonly setKey: string;
504
- readonly timeLimitSeconds: number;
502
+ readonly sectionCount: number;
503
+ readonly setCount: number;
505
504
  readonly trackKey: string;
506
- readonly visibility: "internal-entry" | "visible";
505
+ readonly trackKind: "subject" | "year";
506
+ readonly visibleSectionCount: number;
507
507
  } | {
508
508
  readonly appLocale: ("de" | "en" | "id") & import("effect/Brand").Brand<"@NakafaAI/AksaraAppLocale">;
509
509
  readonly description?: string | undefined;
@@ -516,11 +516,12 @@ export declare function decodeContentSnapshotRows<E, R>(rows: Stream.Stream<unkn
516
516
  };
517
517
  readonly sourceRevision: string;
518
518
  readonly title: string;
519
- readonly countryCode: string;
520
519
  readonly countryKey: string;
521
- readonly kind: "country";
520
+ readonly examKey: string;
521
+ readonly kind: "exam";
522
522
  readonly order: number;
523
523
  readonly publicPath: string & import("effect/Brand").Brand<"@NakafaAI/AksaraPublicPath">;
524
+ readonly scoringStrategy: "irt" | "raw";
524
525
  } | {
525
526
  readonly appLocale: ("de" | "en" | "id") & import("effect/Brand").Brand<"@NakafaAI/AksaraAppLocale">;
526
527
  readonly description?: string | undefined;
@@ -533,12 +534,11 @@ export declare function decodeContentSnapshotRows<E, R>(rows: Stream.Stream<unkn
533
534
  };
534
535
  readonly sourceRevision: string;
535
536
  readonly title: string;
537
+ readonly countryCode: string;
536
538
  readonly countryKey: string;
537
- readonly examKey: string;
538
- readonly kind: "exam";
539
+ readonly kind: "country";
539
540
  readonly order: number;
540
541
  readonly publicPath: string & import("effect/Brand").Brand<"@NakafaAI/AksaraPublicPath">;
541
- readonly scoringStrategy: "irt" | "raw";
542
542
  };
543
543
  readonly rowHash: string & import("effect/Brand").Brand<"@NakafaAI/AksaraSha256Hash">;
544
544
  };
@@ -570,17 +570,12 @@ export declare function decodeContentSnapshotRows<E, R>(rows: Stream.Stream<unkn
570
570
  readonly questionSourcePath: string & import("effect/Brand").Brand<"@NakafaAI/AksaraCorpusSourcePath">;
571
571
  readonly rendererDomain: "ai-ds" | "biology" | "chemistry" | "mathematics" | "physics" | "politics" | "site" | "snbt-general" | "snbt-math" | "snbt-plain" | "snbt-quant" | "tka-math";
572
572
  readonly response: {
573
- readonly categories: readonly {
574
- readonly categoryKey: string;
575
- readonly label: string;
576
- readonly order: number;
577
- }[];
578
- readonly kind: "category";
579
- readonly statements: readonly {
580
- readonly correctCategoryKey: string;
573
+ readonly kind: "single-choice";
574
+ readonly options: readonly {
575
+ readonly isCorrect: boolean;
581
576
  readonly label: string;
577
+ readonly optionKey: string;
582
578
  readonly order: number;
583
- readonly statementKey: string;
584
579
  }[];
585
580
  } | {
586
581
  readonly kind: "multiple-choice";
@@ -591,13 +586,18 @@ export declare function decodeContentSnapshotRows<E, R>(rows: Stream.Stream<unkn
591
586
  readonly order: number;
592
587
  }[];
593
588
  } | {
594
- readonly kind: "single-choice";
595
- readonly options: readonly {
596
- readonly isCorrect: boolean;
589
+ readonly categories: readonly {
590
+ readonly categoryKey: string;
597
591
  readonly label: string;
598
- readonly optionKey: string;
599
592
  readonly order: number;
600
593
  }[];
594
+ readonly kind: "category";
595
+ readonly statements: readonly {
596
+ readonly correctCategoryKey: string;
597
+ readonly label: string;
598
+ readonly order: number;
599
+ readonly statementKey: string;
600
+ }[];
601
601
  };
602
602
  readonly scope: "server";
603
603
  readonly sectionKey: string;
@@ -572,7 +572,11 @@ export declare const decodePublicContentRuntimeResponse: (input: unknown) => Eff
572
572
  readonly delivery: "public";
573
573
  readonly projection: {
574
574
  readonly appLocale: ("de" | "en" | "id") & import("effect/Brand").Brand<"@NakafaAI/AksaraAppLocale">;
575
+ readonly articleRouteSlug: string & import("effect/Brand").Brand<"@NakafaAI/AksaraArticleRouteSlug">;
576
+ readonly articleSlug: string & import("effect/Brand").Brand<"@NakafaAI/AksaraArticleSlug">;
575
577
  readonly artifactLocale: ("de" | "en" | "id") & import("effect/Brand").Brand<"@NakafaAI/AksaraArtifactLocale">;
578
+ readonly category: string & import("effect/Brand").Brand<"@NakafaAI/AksaraArticleCategory">;
579
+ readonly categoryRouteSlug: string & import("effect/Brand").Brand<"@NakafaAI/AksaraArticleRouteSlug">;
576
580
  readonly contentKey: string & import("effect/Brand").Brand<"@NakafaAI/AksaraContentKey">;
577
581
  readonly graph: {
578
582
  readonly alignmentId: string;
@@ -581,11 +585,9 @@ export declare const decodePublicContentRuntimeResponse: (input: unknown) => Eff
581
585
  readonly learningObjectId: string;
582
586
  readonly lensId: string;
583
587
  };
584
- readonly materialKey: string & import("effect/Brand").Brand<"@NakafaAI/AksaraMaterialKey">;
585
- readonly order: number;
586
588
  readonly publicPath: string & import("effect/Brand").Brand<"@NakafaAI/AksaraPublicPath">;
587
- readonly sectionKey: string & import("effect/Brand").Brand<"@NakafaAI/AksaraMaterialSection">;
588
- readonly kind: "subject-lesson";
589
+ readonly categoryTitle: string;
590
+ readonly kind: "article";
589
591
  readonly metadata: {
590
592
  readonly dateModified?: string;
591
593
  readonly datePublished: string;
@@ -593,19 +595,23 @@ export declare const decodePublicContentRuntimeResponse: (input: unknown) => Eff
593
595
  readonly name: string;
594
596
  }[];
595
597
  readonly description?: string | undefined;
596
- readonly subject?: string | undefined;
597
598
  readonly title: string;
598
599
  };
600
+ readonly official: boolean;
599
601
  readonly parentPath: string & import("effect/Brand").Brand<"@NakafaAI/AksaraPublicPath">;
602
+ readonly references: readonly {
603
+ readonly authors: string;
604
+ readonly citation?: string | undefined;
605
+ readonly details?: string | undefined;
606
+ readonly publication?: string | undefined;
607
+ readonly title: string;
608
+ readonly url?: string | undefined;
609
+ readonly year: number;
610
+ }[];
600
611
  readonly sitemap: true;
601
- readonly topicTitle: string;
602
612
  } | {
603
613
  readonly appLocale: ("de" | "en" | "id") & import("effect/Brand").Brand<"@NakafaAI/AksaraAppLocale">;
604
- readonly articleRouteSlug: string & import("effect/Brand").Brand<"@NakafaAI/AksaraArticleRouteSlug">;
605
- readonly articleSlug: string & import("effect/Brand").Brand<"@NakafaAI/AksaraArticleSlug">;
606
614
  readonly artifactLocale: ("de" | "en" | "id") & import("effect/Brand").Brand<"@NakafaAI/AksaraArtifactLocale">;
607
- readonly category: string & import("effect/Brand").Brand<"@NakafaAI/AksaraArticleCategory">;
608
- readonly categoryRouteSlug: string & import("effect/Brand").Brand<"@NakafaAI/AksaraArticleRouteSlug">;
609
615
  readonly contentKey: string & import("effect/Brand").Brand<"@NakafaAI/AksaraContentKey">;
610
616
  readonly graph: {
611
617
  readonly alignmentId: string;
@@ -614,9 +620,11 @@ export declare const decodePublicContentRuntimeResponse: (input: unknown) => Eff
614
620
  readonly learningObjectId: string;
615
621
  readonly lensId: string;
616
622
  };
623
+ readonly materialKey: string & import("effect/Brand").Brand<"@NakafaAI/AksaraMaterialKey">;
624
+ readonly order: number;
617
625
  readonly publicPath: string & import("effect/Brand").Brand<"@NakafaAI/AksaraPublicPath">;
618
- readonly categoryTitle: string;
619
- readonly kind: "article";
626
+ readonly sectionKey: string & import("effect/Brand").Brand<"@NakafaAI/AksaraMaterialSection">;
627
+ readonly kind: "subject-lesson";
620
628
  readonly metadata: {
621
629
  readonly dateModified?: string;
622
630
  readonly datePublished: string;
@@ -624,20 +632,12 @@ export declare const decodePublicContentRuntimeResponse: (input: unknown) => Eff
624
632
  readonly name: string;
625
633
  }[];
626
634
  readonly description?: string | undefined;
635
+ readonly subject?: string | undefined;
627
636
  readonly title: string;
628
637
  };
629
- readonly official: boolean;
630
638
  readonly parentPath: string & import("effect/Brand").Brand<"@NakafaAI/AksaraPublicPath">;
631
- readonly references: readonly {
632
- readonly authors: string;
633
- readonly citation?: string | undefined;
634
- readonly details?: string | undefined;
635
- readonly publication?: string | undefined;
636
- readonly title: string;
637
- readonly url?: string | undefined;
638
- readonly year: number;
639
- }[];
640
639
  readonly sitemap: true;
640
+ readonly topicTitle: string;
641
641
  } | {
642
642
  readonly appLocale: ("de" | "en" | "id") & import("effect/Brand").Brand<"@NakafaAI/AksaraAppLocale">;
643
643
  readonly artifactLocale: ("de" | "en" | "id") & import("effect/Brand").Brand<"@NakafaAI/AksaraArtifactLocale">;