Skip to content

Commit 014bbbd

Browse files
authored
Merge pull request #128 from Green-Software-Foundation/rename-manifest-to-imp
Rename manifest to imp
2 parents ad17086 + 234e3af commit 014bbbd

35 files changed

+338
-255
lines changed

.vscode/settings.json

+44
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
{
2+
"grammarly.selectors": [
3+
{
4+
"language": "markdown",
5+
"scheme": "file",
6+
"pattern": "docs/FAQ.md"
7+
},
8+
{
9+
"language": "markdown",
10+
"scheme": "file",
11+
"pattern": "docs/reference/errors.md"
12+
},
13+
{
14+
"language": "markdown",
15+
"scheme": "file",
16+
"pattern": "docs/users/how-to-compare-files-with-if-diff.md"
17+
},
18+
{
19+
"language": "markdown",
20+
"scheme": "file",
21+
"pattern": "docs/reference/plugins.md"
22+
},
23+
{
24+
"language": "markdown",
25+
"scheme": "file",
26+
"pattern": "docs/pipelines/sci.md"
27+
},
28+
{
29+
"language": "markdown",
30+
"scheme": "file",
31+
"pattern": "docs/reference/cli.md"
32+
},
33+
{
34+
"language": "markdown",
35+
"scheme": "file",
36+
"pattern": "docs/users/how-to-verify-files-with-if-check.md"
37+
},
38+
{
39+
"language": "markdown",
40+
"scheme": "file",
41+
"pattern": "docs/users/how-to-use-the-explain-feature.md"
42+
}
43+
]
44+
}

docs/FAQ.md

+8-8
Original file line numberDiff line numberDiff line change
@@ -11,27 +11,27 @@ To contribute to these docs, you can raise pull requests against our [Github rep
1111

1212
In general, you can consider any ticket on our [issue board](https://github.com/Green-Software-Foundation/if/issues) open for community contributions if it *does not* have the `core-only` tag. We tag suitable introductory issues as `good-first-issue` - these are great places to get started.
1313

14-
## Is there any way to auto-generate manifest files?
14+
## Is there any way to auto-generate IMP files?
1515

16-
Not really. We provide a command line tool called `if-env` which will generate a template manifest for you if you run it in an empty folder. We also provide a built-in feature called `mockObservations` that will autogenerate some input data for you (designed to generate dummy data for experimenting or scenario testing). There are also `importer` plugins that will pull data from files or APIs into IF manifests. However, we do not currently provide any tooling that will generate a full manifest file for you - we think humans in the loop are important for ensuring the nuances of your system are captured in the manifest and in general, we'd prefer not to automate that away. That said, there is potential for tooling that helps abstract out the more repetitive tasks associated with building large manifest files.
16+
Not really. We provide a command line tool called `if-env` which will generate a template IMP for you if you run it in an empty folder. We also provide a built-in feature called `mockObservations` that will autogenerate some input data for you (designed to generate dummy data for experimenting or scenario testing). There are also `importer` plugins that will pull data from files or APIs into IF IMPs. However, we do not currently provide any tooling that will generate a full IMP file for you - we think humans in the loop are important for ensuring the nuances of your system are captured in the IMP and in general, we'd prefer not to automate that away. That said, there is potential for tooling that helps abstract out the more repetitive tasks associated with building large IMP files.
1717

18-
## Where do I get the data for my manifest file?
18+
## Where do I get the data for my IMP file?
1919

20-
This is up to you! One of the strengths of the IF is that you can build manifests your way. We expect input data to come from an external file or an API in most cases, although you can manually add input data into your manifest too. People have built importer plugins for Azure's monitor API, Prometheus databases, CSV files, Datadog, and others. These importer plugins can be found on the [Explorer website](https://explorer.if.greensoftware.foundation).
20+
This is up to you! One of the strengths of the IF is that you can build IMPs your way. We expect input data to come from an external file or an API in most cases, although you can manually add input data into your IMP too. People have built importer plugins for Azure's monitor API, Prometheus databases, CSV files, Datadog, and others. These importer plugins can be found on the [Explorer website](https://explorer.if.greensoftware.foundation).
2121

2222
## What is your vision for the IF?
2323

24-
The vision is to build a protocol that enables you to calculate the appropriate environmental impact for your application, whatever it is. We want to be an open communication standard - our dream is that an IF manifest is the primary way that people share the environmental impacts of their systems.
24+
The vision is to build a protocol that enables you to calculate the appropriate environmental impact for your application, whatever it is. We want to be an open communication standard - our dream is that an IF IMP is the primary way that people share the environmental impacts of their systems.
2525

2626
Right now we consider our core functionality to be calculating software carbon intensity scores for software applications running in the cloud, but we have people using IF on-premise and even for supply chain modeling and other non-software applications. The idea is that we provide the minimal infrastructure required for you to build up different use cases using plugins.
2727

2828
## Is there a way to generate an audit/report along with a csv/yaml output?
2929

30-
No - we see the manifest file and associated manifest as a new type of "executable audit". The IF itself does not generate any other form of report, although there is nothing stopping others from building out this functionality on top of IF.
30+
No - we see the IMP file and associated IMP as a new type of "executable audit". The IF itself does not generate any other form of report, although there is nothing stopping others from building out this functionality on top of IF.
3131

3232
## IF makes things transparent, but how can you fight against users inputting incorrect or misleading data?
3333

34-
We can't really stop people providing fake data into a manifest file. We're very interested in ways we can verify that the computation was done correctly and provide public proofs, but without direct access to a user's systems we can never guarantee they are providing truthful data. This is not unique to IF - fraud is a problem across all industries.
34+
We can't really stop people providing fake data into an IMP file. We're very interested in ways we can verify that the computation was done correctly and provide public proofs, but without direct access to a user's systems we can never guarantee they are providing truthful data. This is not unique to IF - fraud is a problem across all industries.
3535

3636
## Is it planned to make the IF more user-friendly or also more usable for less technical people?
3737

@@ -47,7 +47,7 @@ No we haven't - we've been focussing on capturing impacts of individual applicat
4747

4848
## Are you planning to support e.g. for PaaS, IaaS, alternative cloud providers...etc?
4949

50-
We are focused on building out the low-level core infrastructure so that users can apply IF to any use case. We do not currently intend to build out support for any specific service. We want users to build plugins and publish them to the [Explorer](https://explorer.if.greensoftware.foundation) and share manifests to support individual use cases.
50+
We are focused on building out the low-level core infrastructure so that users can apply IF to any use case. We do not currently intend to build out support for any specific service. We want users to build plugins and publish them to the [Explorer](https://explorer.if.greensoftware.foundation) and share IMPs to support individual use cases.
5151

5252

5353
## What is on your roadmap?

docs/developers/how-to-build-plugins.md

+12-12
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ To help developers write Typescript plugins to integrate easily into IF, we prov
99

1010
- create a Typescript file that implements the `PluginFactory` from [`if-core`](https://github.com/Green-Software-Foundation/if-core)
1111
- install the plugin
12-
- initialize and invoke the plugin in your manifest file
12+
- initialize and invoke the plugin in your IMP file
1313

1414
## Step 1: Use our template repository
1515

@@ -59,7 +59,7 @@ The inner function returned by the `PluginFactory` handles the following paramet
5959

6060
### Config
6161

62-
The `config` object is passed as an argument to your plugin and can be handled as shown in the example above. The structure of the config depends on what is defined in the manifest file. For example, the `Sci` plugin has access to `input-parameters` and `output-parameter` fields in its global configuration, as defined in the `Initialize` block of the manifest file:
62+
The `config` object is passed as an argument to your plugin and can be handled as shown in the example above. The structure of the config depends on what is defined in the IMP file. For example, the `Sci` plugin has access to `input-parameters` and `output-parameter` fields in its global configuration, as defined in the `Initialize` block of the IMP file:
6363

6464
```yaml
6565
initialize:
@@ -74,7 +74,7 @@ initialize:
7474
7575
### Parameter metadata
7676
77-
The `parameter-metadata` is passed as an argument to the plugin as the config. It contains information about the `description`, `unit` and `aggregation-method` of the parameters of the inputs and outputs that defined in the manifest.
77+
The `parameter-metadata` is passed as an argument to the plugin as the config. It contains information about the `description`, `unit` and `aggregation-method` of the parameters of the inputs and outputs that defined in the IMP.
7878

7979
```yaml
8080
initialize:
@@ -234,7 +234,7 @@ Additional Notes
234234

235235
- `Implement`: You should implement `implementation` function. It should contains the primary logic to generate outputs.
236236
- `Validation`: You should define appropriate `zod` schemas or validation functions for both config and inputs. This ensures that invalid data is caught early and handled appropriately.
237-
- `Arithmetic Expressions`: By including configuration, input, and output parameters of the plugin in the `allowArithmeticExpressions` array, you enable dynamic evaluation of mathematical expressions within parameter values. This eliminates the need for manual pre-calculation and allows basic mathematical operations to be embedded directly within parameter values in manifest files. More details [here.](../reference/features.md)
237+
- `Arithmetic Expressions`: By including configuration, input, and output parameters of the plugin in the `allowArithmeticExpressions` array, you enable dynamic evaluation of mathematical expressions within parameter values. This eliminates the need for manual pre-calculation and allows basic mathematical operations to be embedded directly within parameter values in IMP files. More details [here.](../reference/features.md)
238238
- `Mapping`: Ensure your plugin correctly handles the mapping of parameters. This is essential when working with dynamic input and output configurations.
239239

240240
## Step 3: Install your plugin
@@ -261,7 +261,7 @@ npm link new-plugin
261261

262262
replacing `new-plugin` with your plugin name as defined in the plugin's `package.json`. If you are not sure, the name can be checked by running `npm ls -g --depth=0 --link=true`.
263263

264-
Your plugin is now ready to be run in IF. All that remains is to add your plugin to your manifest file. This means adding it to the `initialize block` and adding it to the component pipelines where you want your plugin to be executed. For example, an `initilize` block might look as follows:
264+
Your plugin is now ready to be run in IF. All that remains is to add your plugin to your IMP file. This means adding it to the `initialize block` and adding it to the component pipelines where you want your plugin to be executed. For example, an `initilize` block might look as follows:
265265

266266
```yaml
267267
initialize:
@@ -273,10 +273,10 @@ initialize:
273273
something: true
274274
```
275275

276-
Run your manifest uisng
276+
Run your IMP uisng
277277

278278
```sh
279-
npm run if-run -- --manifest <path-to-manifest>
279+
npm run if-run -- --manifest <path-to-imp>
280280
```
281281

282282
If you have to link more than one local plugin, for example to test your plugin in a pipeline, you can do so with
@@ -289,15 +289,15 @@ This will create an entry like `"new-plugin": "file:path/to/your/plugin"` in the
289289

290290
## Step 5: Publishing your plugin
291291

292-
Now you have run your plugin locally and you are happy with how it works, you can make it public by publishing it to a public Github repository. Now all you have to do to use it in a manifest file is `npm install` it and pass the path to the Github repository in the plugin `initialize` block.
292+
Now you have run your plugin locally and you are happy with how it works, you can make it public by publishing it to a public Github repository. Now all you have to do to use it in an IMP file is `npm install` it and pass the path to the Github repository in the plugin `initialize` block.
293293

294294
For example, for a plugin saved in `github.com/my-repo/new-plugin` you can do the following:
295295

296296
```
297297
npm install https://github.com/my-repo/new-plugin
298298
```
299299

300-
Then, in your manifest file, provide the path in the plugin instantiation. You also need to specify which function the plugin instantiates. Let's say you are using the `Sci` plugin from the example above:
300+
Then, in your IMP file, provide the path in the plugin instantiation. You also need to specify which function the plugin instantiates. Let's say you are using the `Sci` plugin from the example above:
301301

302302
```yaml
303303
name: plugin-demo
@@ -314,12 +314,12 @@ tree:
314314
inputs:
315315
```
316316

317-
Now, when you run the manifest file, it will load the plugin automatically.
317+
Now, when you run the IMP file, it will load the plugin automatically.
318318

319319
You can run this using the globally installed IF as follows:
320320

321321
```sh
322-
if-run --manifest <path-to-my-manifest>
322+
if-run --manifest <path-to-my-imp>
323323
```
324324

325325
## Summary of steps
@@ -328,7 +328,7 @@ if-run --manifest <path-to-my-manifest>
328328
- Add your plugin code to `index.ts`
329329
- Build and link the plugin using `npm run build && npm link`
330330
- Load your plugin into `if` using `npm link`
331-
- Initialize your plugin and add it to a pipeline in your manifest file.
331+
- Initialize your plugin and add it to a pipeline in your IMP file.
332332
- Publish your plugin to Github
333333

334334
You should also create unit tests for your plugin to demonstrate correct execution and handling of corner cases.

docs/developers/how-to-create-exhaust-script.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ sidebar-position: 6
77
The `IF` framework outputs data in `yaml` format. Any other output formats require a separate script that takes the yaml output data and processes it. We provide [`if-csv`](../users/how-to-export-csv-file-with-if-csv.md) for outputting data in `csv` format bundled with IF. For any other format, you need to write an exhaust script.
88
This guide will help you create your own exhaust script.
99

10-
In this example, we'll create a script that executes the manifest and outputs the data in `json` format.
10+
In this example, we'll create a script that executes the IMP and outputs the data in `json` format.
1111

1212
```ts
1313
const IfJson = async () => {
@@ -42,4 +42,4 @@ To add this script to your package.json, include the following entry in the scri
4242
}
4343
```
4444

45-
This setup ensures that your script will execute the manifest and output the data in JSON format.
45+
This setup ensures that your script will execute the IMP and output the data in JSON format.

docs/developers/how-to-submit-plugins.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ Your plugin documentation should include the following information:
3030
- A description of any environment setup such as credentials in environment variables, etc. (REQUIRED)
3131
- Installation instructions (REQUIRED)
3232
- A written description of the plugin behaviour (REQUIRED)
33-
- A demo manifest that executes the plugin correctly without errors (REQUIRED)
33+
- A demo IMP that executes the plugin correctly without errors (REQUIRED)
3434
- A link to your unit tests
3535
- A list of errors that your plugin can raise, the behaviours that cause them and potential remedies.
3636
- A reference list of any publications or other material supporting the approach you have taken in your plugin.

docs/intro.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ sidebar_position: 1
1010

1111
Impact Framework (IF) aims to make the environmental impacts of software easier to calculate **and** share.
1212

13-
IF allows you to calculate the environmental impacts, such as carbon, of your software applications without writing any code. All you have to do is write a simple **manifest file** and IF handles the rest.
13+
IF allows you to calculate the environmental impacts, such as carbon, of your software applications without writing any code. All you have to do is write a simple **IMP file** and IF handles the rest.
1414

1515
The project is entirely open source and composability is a core design principle - we want you to be able to create your own plugins and plug them in to our framework, or pick from a broad universe of open source plugins created by others.
1616

docs/major-concepts/aggregation.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ Assuming the aggregation method is `sum`, the parent would receive an aggregated
2222

2323
## Configuration
2424

25-
`Aggregate` is a built-in feature of the IF. This means you do not need to initialize it along with the plugins you are using in your pipeline. All you need to do is to add a small piece of config to your manifest file.
25+
`Aggregate` is a built-in feature of the IF. This means you do not need to initialize it along with the plugins you are using in your pipeline. All you need to do is to add a small piece of config to your IMP file.
2626

2727
The `aggregate` config looks as follows:
2828

@@ -50,7 +50,7 @@ Similarly, some values are proportions or percentages. In these cases, the right
5050

5151
## Aggregation outputs
5252

53-
The aggregation process adds new output data to your manifest file. The two types of aggregation add different outputs. The horizontal (time-series) aggregation adds a new field called `aggregated` to each node whose time series has been aggregated. In the `aggregated` block, you will find the aggregated value for each of the aggregation metrics defined in the aggregation config.
53+
The aggregation process adds new output data to your IMP file. The two types of aggregation add different outputs. The horizontal (time-series) aggregation adds a new field called `aggregated` to each node whose time series has been aggregated. In the `aggregated` block, you will find the aggregated value for each of the aggregation metrics defined in the aggregation config.
5454

5555
The vertical aggregation adds a new array of output observations. These are simply named `outputs` and they always contain a timestamp and duration along with the aggregated metrics for each timestep.
5656

0 commit comments

Comments
 (0)