@intentius/chant-lexicon-aws 0.66.0 → 0.67.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.
@@ -0,0 +1,17 @@
1
+ /**
2
+ * What this lexicon's entity types are worth to a behaviour engine (#2382).
3
+ *
4
+ * Contributed as rows through the plugin's `behaviourKinds` field; the
5
+ * vocabulary, the resolution and the prediction are
6
+ * `packages/core/src/behaviour-kinds.ts`. These rows were a section of one
7
+ * cross-lexicon table in one lexicon until #2382 moved each substrate's
8
+ * rows to the lexicon that owns the types — this file can say what
9
+ * `AWS::EC2::Instance` means because it is the file that defines it.
10
+ *
11
+ * A table rather than a heuristic over type names: a heuristic would map
12
+ * `AWS::EC2::VolumeAttachment` to storage and price a join table.
13
+ */
14
+ import type { BehaviourKinds } from "@intentius/chant/behaviour-kinds";
15
+ /** This lexicon's answer for its own types. */
16
+ export declare const awsBehaviourKinds: BehaviourKinds;
17
+ //# sourceMappingURL=behaviour-kinds.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"behaviour-kinds.d.ts","sourceRoot":"","sources":["../src/behaviour-kinds.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAEH,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,kCAAkC,CAAC;AAmGvE,+CAA+C;AAC/C,eAAO,MAAM,iBAAiB,EAAE,cAM/B,CAAC"}
@@ -23,12 +23,12 @@ export type LambdaFunctionResult = {
23
23
  export declare const LambdaFunction: import("@intentius/chant").CompositeDefinition<LambdaFunctionProps, LambdaFunctionResult>;
24
24
  export declare const LambdaNode: import("@intentius/chant").CompositeDefinition<{
25
25
  name: string | ReturnType<typeof Sub>;
26
+ MemorySize?: number | undefined;
26
27
  Code: ConstructorParameters<typeof Function>[0]["Code"];
27
28
  Policies?: InstanceType<typeof Role_Policy>[] | undefined;
28
29
  Environment?: ConstructorParameters<typeof Function>[0]["Environment"];
29
30
  VpcConfig?: ConstructorParameters<typeof Function_VpcConfig>[0] | undefined;
30
31
  ManagedPolicyArns?: string[] | undefined;
31
- MemorySize?: number | undefined;
32
32
  Timeout?: number | undefined;
33
33
  defaults?: {
34
34
  role?: Partial<ConstructorParameters<typeof Role>[0]>;
@@ -39,12 +39,12 @@ export declare const LambdaNode: import("@intentius/chant").CompositeDefinition<
39
39
  }, LambdaFunctionResult>;
40
40
  export declare const LambdaPython: import("@intentius/chant").CompositeDefinition<{
41
41
  name: string | ReturnType<typeof Sub>;
42
+ MemorySize?: number | undefined;
42
43
  Code: ConstructorParameters<typeof Function>[0]["Code"];
43
44
  Policies?: InstanceType<typeof Role_Policy>[] | undefined;
44
45
  Environment?: ConstructorParameters<typeof Function>[0]["Environment"];
45
46
  VpcConfig?: ConstructorParameters<typeof Function_VpcConfig>[0] | undefined;
46
47
  ManagedPolicyArns?: string[] | undefined;
47
- MemorySize?: number | undefined;
48
48
  Timeout?: number | undefined;
49
49
  defaults?: {
50
50
  role?: Partial<ConstructorParameters<typeof Role>[0]>;
@@ -56,12 +56,12 @@ export declare const LambdaPython: import("@intentius/chant").CompositeDefinitio
56
56
  /** @deprecated Use `LambdaNode` instead */
57
57
  export declare const NodeLambda: import("@intentius/chant").CompositeDefinition<{
58
58
  name: string | ReturnType<typeof Sub>;
59
+ MemorySize?: number | undefined;
59
60
  Code: ConstructorParameters<typeof Function>[0]["Code"];
60
61
  Policies?: InstanceType<typeof Role_Policy>[] | undefined;
61
62
  Environment?: ConstructorParameters<typeof Function>[0]["Environment"];
62
63
  VpcConfig?: ConstructorParameters<typeof Function_VpcConfig>[0] | undefined;
63
64
  ManagedPolicyArns?: string[] | undefined;
64
- MemorySize?: number | undefined;
65
65
  Timeout?: number | undefined;
66
66
  defaults?: {
67
67
  role?: Partial<ConstructorParameters<typeof Role>[0]>;
@@ -73,12 +73,12 @@ export declare const NodeLambda: import("@intentius/chant").CompositeDefinition<
73
73
  /** @deprecated Use `LambdaPython` instead */
74
74
  export declare const PythonLambda: import("@intentius/chant").CompositeDefinition<{
75
75
  name: string | ReturnType<typeof Sub>;
76
+ MemorySize?: number | undefined;
76
77
  Code: ConstructorParameters<typeof Function>[0]["Code"];
77
78
  Policies?: InstanceType<typeof Role_Policy>[] | undefined;
78
79
  Environment?: ConstructorParameters<typeof Function>[0]["Environment"];
79
80
  VpcConfig?: ConstructorParameters<typeof Function_VpcConfig>[0] | undefined;
80
81
  ManagedPolicyArns?: string[] | undefined;
81
- MemorySize?: number | undefined;
82
82
  Timeout?: number | undefined;
83
83
  defaults?: {
84
84
  role?: Partial<ConstructorParameters<typeof Role>[0]>;
@@ -1 +1 @@
1
- {"version":3,"file":"lambda-function.d.ts","sourceRoot":"","sources":["../../src/composites/lambda-function.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,IAAI,EAAE,QAAQ,EAAE,kBAAkB,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAC/E,OAAO,EAAE,GAAG,EAAE,MAAM,eAAe,CAAC;AAkBpC,MAAM,WAAW,mBAAmB;IAClC,IAAI,EAAE,MAAM,GAAG,UAAU,CAAC,OAAO,GAAG,CAAC,CAAC;IACtC,OAAO,EAAE,MAAM,CAAC;IAChB,OAAO,EAAE,MAAM,CAAC;IAChB,IAAI,EAAE,qBAAqB,CAAC,OAAO,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC;IACxD,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,WAAW,CAAC,EAAE,qBAAqB,CAAC,OAAO,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,aAAa,CAAC,CAAC;IACvE,iBAAiB,CAAC,EAAE,MAAM,EAAE,CAAC;IAC7B,QAAQ,CAAC,EAAE,YAAY,CAAC,OAAO,WAAW,CAAC,EAAE,CAAC;IAC9C,SAAS,CAAC,EAAE,qBAAqB,CAAC,OAAO,kBAAkB,CAAC,CAAC,CAAC,CAAC,CAAC;IAChE,QAAQ,CAAC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Y,CAAC,OAAO,WAAW,CAAC,EAAE;kBAF/B,qBAAqB,CAAC,OAAO,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,aAAa,CAAC;gBAG1D,qBAAqB,CAAC,OAAO,kBAAkB,CAAC,CAAC,CAAC,CAAC;wBAF3C,MAAM,EAAE;cAHlB,MAAM;eAML;QACT,IAAI,CAAC,EAAE,OAAO,CAAC,qBAAqB,CAAC,OAAO,IAAI,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;QACtD,IAAI,CAAC,EAAE,OAAO,CAAC,qBAAqB,CAAC,OAAO,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;KAC3D;;;wBAoDqC,CAAC"}
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "algorithm": "sha256",
3
3
  "artifacts": {
4
- "manifest.json": "79cdc20d28b713374552cb67ad7778b2610365351cfd9fcd7eddb236b3df8d64",
4
+ "manifest.json": "0849f6e08e0fd0e410e6925446d47f1c8e8702b68bc7303b8382c63916f591cc",
5
5
  "meta.json": "31795ba62a1da7503a8d55192c212ac44c56a56cdb2d4fde47966a1abc8b021b",
6
6
  "types/index.d.ts": "1038589dccfc1e690e3373014bff4d319e4ed3b421db2448ed4e70d51eb9d1f2",
7
7
  "rules/hardcoded-region.ts": "5a0eaf7ab391231fe6cd51426ece29539cb4b36f31c8dd060956638fed55722a",
@@ -73,5 +73,5 @@
73
73
  "skills/chant-aws-eks.md": "8789255709ff004ad0a875fd5999edcdc66fc6e33d710db058d9f42703bcfdfe",
74
74
  "skills/chant-aws-carve-terraform.md": "0ae4376590db47979be144d3ac6cdcfd56c9640d0536421aacf7330459d38e52"
75
75
  },
76
- "composite": "dd99c7ddd0a089e6e988965efaf94c59cc99b8a3ba3b9ab04b6da7984a33f64a"
76
+ "composite": "4edcb71f2b3b2f84f8940be31c7b5dbb482f5d0d9fdafe17eda0b163a30b14ff"
77
77
  }
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "aws",
3
- "version": "0.66.0",
3
+ "version": "0.67.0",
4
4
  "chantVersion": ">=0.1.0",
5
5
  "namespace": "AWS",
6
6
  "intrinsics": [
@@ -1 +1 @@
1
- {"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../src/plugin.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,aAAa,EAAqQ,MAAM,0BAA0B,CAAC;AAuCjU;yEACyE;AACzE,OAAO,EAAE,iBAAiB,EAAE,MAAM,gBAAgB,CAAC;AAiBnD,eAAO,MAAM,SAAS,EAAE,aAkgCvB,CAAC"}
1
+ {"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../src/plugin.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,aAAa,EAAqQ,MAAM,0BAA0B,CAAC;AAuCjU;yEACyE;AACzE,OAAO,EAAE,iBAAiB,EAAE,MAAM,gBAAgB,CAAC;AAiBnD,eAAO,MAAM,SAAS,EAAE,aAmgCvB,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@intentius/chant-lexicon-aws",
3
- "version": "0.66.0",
3
+ "version": "0.67.0",
4
4
  "description": "AWS CloudFormation lexicon for chant — declarative IaC in TypeScript",
5
5
  "license": "Apache-2.0",
6
6
  "homepage": "https://intentius.io/chant",
@@ -80,7 +80,7 @@
80
80
  "typescript": "^5.9.3"
81
81
  },
82
82
  "peerDependencies": {
83
- "@intentius/chant": "^0.66.0",
83
+ "@intentius/chant": "^0.67.0",
84
84
  "typescript": "^5.9.3"
85
85
  }
86
86
  }
@@ -0,0 +1,121 @@
1
+ /**
2
+ * What this lexicon's entity types are worth to a behaviour engine (#2382).
3
+ *
4
+ * Contributed as rows through the plugin's `behaviourKinds` field; the
5
+ * vocabulary, the resolution and the prediction are
6
+ * `packages/core/src/behaviour-kinds.ts`. These rows were a section of one
7
+ * cross-lexicon table in one lexicon until #2382 moved each substrate's
8
+ * rows to the lexicon that owns the types — this file can say what
9
+ * `AWS::EC2::Instance` means because it is the file that defines it.
10
+ *
11
+ * A table rather than a heuristic over type names: a heuristic would map
12
+ * `AWS::EC2::VolumeAttachment` to storage and price a join table.
13
+ */
14
+
15
+ import type { BehaviourKinds } from "@intentius/chant/behaviour-kinds";
16
+
17
+ /** Types an engine prices, with the declared property its size is read from. */
18
+ const MAPPED: BehaviourKinds["mapped"] = {
19
+
20
+ "AWS::EC2::Instance": { kind: "compute", sizeProp: "InstanceType", sizeType: "string" },
21
+ "AWS::EC2::Volume": { kind: "block-store", sizeProp: "Size", sizeType: "number", regionProp: "AvailabilityZone" },
22
+ "AWS::Lambda::Function": { kind: "serverless", sizeProp: "MemorySize", sizeType: "number" },
23
+ "AWS::RDS::DBInstance": { kind: "database", sizeProp: "DBInstanceClass", sizeType: "string" },
24
+ "AWS::RDS::DBCluster": { kind: "database", sizeProp: "DBClusterInstanceClass", sizeType: "string" },
25
+ "AWS::DynamoDB::Table": { kind: "database", sizeProp: "BillingMode", sizeType: "string" },
26
+ "AWS::ElastiCache::CacheCluster": { kind: "cache", sizeProp: "CacheNodeType", sizeType: "string" },
27
+ "AWS::SQS::Queue": { kind: "queue" },
28
+ "AWS::SNS::Topic": { kind: "queue" },
29
+ "AWS::S3::Bucket": { kind: "object-store" },
30
+ "AWS::ElasticLoadBalancingV2::LoadBalancer": { kind: "load-balancer", sizeProp: "Type", sizeType: "string" },
31
+ "AWS::CloudFront::Distribution": { kind: "cdn" },
32
+ /** A flat hourly fee for the managed control plane. It does not move with the estate's traffic. */
33
+ "AWS::EKS::Cluster": { kind: "control-plane" },
34
+ /**
35
+ * A set of EC2 instances, and what an EKS estate actually costs. No size:
36
+ * `InstanceTypes` is a list, and this contract's `size` is one string.
37
+ */
38
+ "AWS::EKS::Nodegroup": { kind: "compute" },
39
+ /** The running thing. Its task definition is the template and carries no rate. */
40
+ "AWS::ECS::Service": { kind: "compute" },
41
+ };
42
+
43
+ /**
44
+ * Types considered and declared unsendable, each with the reason it carries no
45
+ * rate. Four of the five families core's contributor guidance names appear
46
+ * here: a grant is not a resource, a boundary is not a node, a meter chant
47
+ * cannot read is not a figure, and a template is not an instance.
48
+ */
49
+ const UNMAPPED: BehaviourKinds["unmapped"] = {
50
+ // ── Grants ───────────────────────────────────────────────────────
51
+ "AWS::IAM::Role": "a role is a grant, not a resource traffic flows through: no rate, no capacity, no verdict under a lost zone",
52
+ "AWS::IAM::Policy": "a policy document is a statement about permission; nothing about it saturates or accrues",
53
+ "AWS::IAM::ManagedPolicy": "a policy document is a statement about permission; nothing about it saturates or accrues",
54
+ "AWS::IAM::InstanceProfile": "a wrapper that hands a role to an instance; the instance carries the figures",
55
+ "AWS::S3::BucketPolicy": "a bucket policy is a grant on the bucket beside it, and the bucket carries the figures",
56
+ "AWS::SQS::QueuePolicy": "a queue policy is a grant on the queue beside it, and the queue carries the figures",
57
+ "AWS::Lambda::Permission": "a grant letting one service invoke a function; the function carries the figures",
58
+ // ── Boundaries, and the wiring that puts things inside them ──────
59
+ "AWS::EC2::VPC": "a network boundary rather than a node: its contribution to a prediction is the zone membership that reaches the engine as containment coverage",
60
+ "AWS::EC2::Subnet": "a network boundary rather than a node: its contribution to a prediction is the zone membership that reaches the engine as containment coverage",
61
+ "AWS::EC2::SecurityGroup": "a filter on edges that already exist, not a thing at either end of one",
62
+ "AWS::EC2::RouteTable": "routing, which decides where an edge goes and is not itself at either end of one",
63
+ "AWS::EC2::Route": "routing, which decides where an edge goes and is not itself at either end of one",
64
+ "AWS::EC2::SubnetRouteTableAssociation": "an association between two boundaries; nothing flows through it that does not already flow through them",
65
+ "AWS::EC2::InternetGateway": "a boundary crossing rather than a resource: no rate of its own and no capacity to saturate",
66
+ "AWS::EC2::VPCGatewayAttachment": "an attachment between two boundaries, and neither end is priced by it",
67
+ "AWS::RDS::DBSubnetGroup": "the set of subnets a database may sit in; the database carries the figures",
68
+ "AWS::ECS::Cluster": "a namespace for services rather than capacity of its own; the services and their nodes carry the figures",
69
+ // ── Meters chant cannot read ─────────────────────────────────────
70
+ "AWS::Logs::LogGroup": "priced by the volume ingested into it, which the declaration does not state and no engine can infer from a graph",
71
+ "AWS::WAFv2::WebACL": "priced by the requests inspected through it, which the declaration does not state",
72
+ "AWS::EC2::NatGateway": "priced as an hourly rate plus a per-gigabyte meter on everything that crosses it. The declaration states the first and nothing at all about the second, and no engine kind here models a half-known price — a figure covering the hourly half alone would read as the cost of the gateway and be wrong by whatever the traffic did",
73
+ "AWS::EC2::EIP": "priced only while it is attached to nothing, which is a fact about the running account rather than about the declaration",
74
+ "AWS::ECR::Repository": "priced by the gigabytes stored in it, which the declaration does not state",
75
+ "AWS::KMS::Key": "priced per key per month plus a per-request meter the declaration does not state, and neither half is an hourly rate",
76
+ "AWS::Route53::HostedZone": "priced per zone per month plus a per-query meter the declaration does not state",
77
+ "AWS::SNS::Subscription": "priced by the notifications delivered through it; the topic is what the graph has an edge to",
78
+ "AWS::Events::Rule": "priced by the events matched, which is a fact about traffic the declaration does not state",
79
+ // ── Templates, not instances ─────────────────────────────────────
80
+ "AWS::ECS::TaskDefinition": "a template a service runs copies of; the service carries the figures, and pricing both would count the estate twice",
81
+ "AWS::Lambda::EventSourceMapping": "the wiring between a queue and a function, both of which are priced where they are declared",
82
+ "AWS::ElasticLoadBalancingV2::TargetGroup": "a set of targets behind a load balancer; the load balancer carries the rate",
83
+ "AWS::ElasticLoadBalancingV2::Listener": "a port on a load balancer; the load balancer carries the rate",
84
+ "AWS::ElasticLoadBalancingV2::ListenerRule": "a routing rule on a listener, and a rule is not a thing at either end of an edge",
85
+ // ── Not resources at all ─────────────────────────────────────────
86
+ "AWS::CloudFormation::Parameter": "a template input, not a thing the account holds. It shapes what is created and is never created itself",
87
+ "AWS::CloudFormation::Condition": "a template predicate deciding whether something is created; it is never created itself",
88
+ // ── Meters on a managed agent runtime ────────────────────────────
89
+ // Bedrock AgentCore is billed per invocation and per token consumed. Neither
90
+ // is in a declaration, and an hourly rate for an agent that ran twice this
91
+ // week would be a number with no relationship to the bill.
92
+ "AWS::BedrockAgentCore::Runtime": "an agent runtime billed per invocation and per token, neither of which the declaration states; there is no hour of existence to price",
93
+ "AWS::BedrockAgentCore::Gateway": "a front door to an agent runtime, billed by what passes through it rather than by existing",
94
+ "AWS::BedrockAgentCore::GatewayTarget": "one target behind a gateway; the gateway and the runtime are where the meters are",
95
+ "AWS::BedrockAgentCore::Memory": "agent memory billed by what is stored and retrieved, which the declaration does not state",
96
+ "AWS::BedrockAgentCore::WorkloadIdentity": "an identity a runtime acts as; a grant, with no rate and no capacity",
97
+ };
98
+
99
+ /**
100
+ * A CloudFormation **property** type — `AWS::S3::Bucket.VersioningConfiguration`
101
+ * — recognised by the dot. These are nested blocks of the resource above them
102
+ * that became entities of their own in the build; there are hundreds, they are
103
+ * never separately priced, and enumerating them one row at a time would bury
104
+ * this table's real decisions under boilerplate.
105
+ */
106
+ function propertyType(type: string): string | undefined {
107
+ return type.includes(".")
108
+ ? "a CloudFormation property type: a nested block of the resource above it, which became an " +
109
+ "entity of its own in the build. The resource carries the figures, and pricing the block as " +
110
+ "well would count part of the estate twice"
111
+ : undefined;
112
+ }
113
+
114
+ /** This lexicon's answer for its own types. */
115
+ export const awsBehaviourKinds: BehaviourKinds = {
116
+ provider: "aws",
117
+ prefixes: ["AWS::"],
118
+ mapped: MAPPED,
119
+ unmapped: UNMAPPED,
120
+ unmappedWhen: propertyType,
121
+ };
package/src/plugin.ts CHANGED
@@ -1,4 +1,5 @@
1
1
  import { createRequire } from "module";
2
+ import { awsBehaviourKinds } from "./behaviour-kinds";
2
3
  import { detectTemplate } from "./detect";
3
4
  import type { LexiconPlugin, IntrinsicDef, ObservationResult, DeepObservationResult, DependencyObservation, DescribeIdentityOptions, DescribeIdentityResult, DisruptionQuery, DisruptionVerdict, ResourceMetadata, ExportedTemplate, ResourceSelector, InitTemplateSet, StackStatusObservation } from "@intentius/chant/lexicon";
4
5
  const require = createRequire(import.meta.url);
@@ -59,6 +60,7 @@ const OWNERSHIP_UNRESOLVED_NOTE =
59
60
  "ownership filter not applied on describeResources (this stack's own tags carry no chant marker, or DescribeStacks did not answer) — returning all, each with the verdict the read supports; use `chant import --from <env> --owned` for ownership-filtered export";
60
61
 
61
62
  export const awsPlugin: LexiconPlugin = {
63
+ behaviourKinds: awsBehaviourKinds,
62
64
  name: "aws",
63
65
  // The thin read's marker channel is the STACK's own tags (#1998), read off
64
66
  // the DescribeStacks call it already makes for the outputs.