@powerhousedao/academy 5.0.0-staging.9 → 5.0.1-staging.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 (108) hide show
  1. package/.vscode/settings.json +1 -1
  2. package/CHANGELOG.md +404 -0
  3. package/README.md +3 -3
  4. package/babel.config.js +1 -1
  5. package/blog/BeyondCommunication-ABlueprintForDevelopment.md +25 -24
  6. package/blog/TheChallengeOfChange.md +21 -21
  7. package/docs/academy/01-GetStarted/00-ExploreDemoPackage.mdx +67 -30
  8. package/docs/academy/01-GetStarted/01-CreateNewPowerhouseProject.md +38 -21
  9. package/docs/academy/01-GetStarted/02-DefineToDoListDocumentModel.md +24 -19
  10. package/docs/academy/01-GetStarted/03-ImplementOperationReducers.md +44 -41
  11. package/docs/academy/01-GetStarted/04-BuildToDoListEditor.md +10 -10
  12. package/docs/academy/01-GetStarted/05-VetraStudio.md +164 -0
  13. package/docs/academy/01-GetStarted/06-ReactorMCP.md +58 -0
  14. package/docs/academy/01-GetStarted/home.mdx +185 -90
  15. package/docs/academy/01-GetStarted/images/Modules.png +0 -0
  16. package/docs/academy/01-GetStarted/images/VetraStudioDrive.png +0 -0
  17. package/docs/academy/01-GetStarted/styles.module.css +5 -5
  18. package/docs/academy/02-MasteryTrack/01-BuilderEnvironment/01-Prerequisites.md +46 -18
  19. package/docs/academy/02-MasteryTrack/01-BuilderEnvironment/02-StandardDocumentModelWorkflow.md +118 -68
  20. package/docs/academy/02-MasteryTrack/01-BuilderEnvironment/03-BuilderTools.md +75 -33
  21. package/docs/academy/02-MasteryTrack/01-BuilderEnvironment/_category_.json +6 -6
  22. package/docs/academy/02-MasteryTrack/02-DocumentModelCreation/01-WhatIsADocumentModel.md +30 -21
  23. package/docs/academy/02-MasteryTrack/02-DocumentModelCreation/02-SpecifyTheStateSchema.md +41 -37
  24. package/docs/academy/02-MasteryTrack/02-DocumentModelCreation/03-SpecifyDocumentOperations.md +29 -25
  25. package/docs/academy/02-MasteryTrack/02-DocumentModelCreation/04-UseTheDocumentModelGenerator.md +36 -37
  26. package/docs/academy/02-MasteryTrack/02-DocumentModelCreation/05-ImplementDocumentReducers.md +128 -109
  27. package/docs/academy/02-MasteryTrack/02-DocumentModelCreation/06-ImplementDocumentModelTests.md +95 -86
  28. package/docs/academy/02-MasteryTrack/02-DocumentModelCreation/07-ExampleToDoListRepository.md +7 -9
  29. package/docs/academy/02-MasteryTrack/02-DocumentModelCreation/_category_.json +6 -6
  30. package/docs/academy/02-MasteryTrack/03-BuildingUserExperiences/01-BuildingDocumentEditors.md +65 -47
  31. package/docs/academy/02-MasteryTrack/03-BuildingUserExperiences/02-ConfiguringDrives.md +77 -62
  32. package/docs/academy/02-MasteryTrack/03-BuildingUserExperiences/03-BuildingADriveExplorer.md +360 -349
  33. package/docs/academy/02-MasteryTrack/03-BuildingUserExperiences/06-DocumentTools/00-DocumentToolbar.mdx +16 -10
  34. package/docs/academy/02-MasteryTrack/03-BuildingUserExperiences/06-DocumentTools/01-OperationHistory.md +10 -7
  35. package/docs/academy/02-MasteryTrack/03-BuildingUserExperiences/06-DocumentTools/02-RevisionHistoryTimeline.md +25 -17
  36. package/docs/academy/02-MasteryTrack/03-BuildingUserExperiences/06-DocumentTools/_category_.json +6 -6
  37. package/docs/academy/02-MasteryTrack/03-BuildingUserExperiences/07-Authorization/01-RenownAuthenticationFlow.md +14 -7
  38. package/docs/academy/02-MasteryTrack/03-BuildingUserExperiences/07-Authorization/02-Authorization.md +0 -1
  39. package/docs/academy/02-MasteryTrack/03-BuildingUserExperiences/07-Authorization/_category_.json +5 -5
  40. package/docs/academy/02-MasteryTrack/03-BuildingUserExperiences/_category_.json +1 -1
  41. package/docs/academy/02-MasteryTrack/04-WorkWithData/01-GraphQLAtPowerhouse.md +45 -33
  42. package/docs/academy/02-MasteryTrack/04-WorkWithData/02-UsingTheAPI.mdx +61 -18
  43. package/docs/academy/02-MasteryTrack/04-WorkWithData/03-UsingSubgraphs.md +50 -54
  44. package/docs/academy/02-MasteryTrack/04-WorkWithData/04-analytics-processor.md +126 -110
  45. package/docs/academy/02-MasteryTrack/04-WorkWithData/05-RelationalDbProcessor.md +75 -45
  46. package/docs/academy/02-MasteryTrack/04-WorkWithData/06-Analytics Engine/GraphQL References/QueryingADocumentWithGraphQL.md +23 -21
  47. package/docs/academy/02-MasteryTrack/04-WorkWithData/06-Analytics Engine/best-practices.md +9 -9
  48. package/docs/academy/02-MasteryTrack/04-WorkWithData/06-Analytics Engine/graphql/index.md +11 -23
  49. package/docs/academy/02-MasteryTrack/04-WorkWithData/06-Analytics Engine/graphql/integration.md +25 -9
  50. package/docs/academy/02-MasteryTrack/04-WorkWithData/06-Analytics Engine/intro.md +10 -10
  51. package/docs/academy/02-MasteryTrack/04-WorkWithData/06-Analytics Engine/typescript/benchmarks.md +1 -1
  52. package/docs/academy/02-MasteryTrack/04-WorkWithData/06-Analytics Engine/typescript/index.md +16 -11
  53. package/docs/academy/02-MasteryTrack/04-WorkWithData/06-Analytics Engine/typescript/memory.md +6 -5
  54. package/docs/academy/02-MasteryTrack/04-WorkWithData/06-Analytics Engine/typescript/schema.md +2 -2
  55. package/docs/academy/02-MasteryTrack/04-WorkWithData/06-Analytics Engine/typescript/utilities.md +7 -5
  56. package/docs/academy/02-MasteryTrack/04-WorkWithData/06-Analytics Engine/use-cases/maker.md +32 -58
  57. package/docs/academy/02-MasteryTrack/04-WorkWithData/06-Analytics Engine/use-cases/processors.md +1 -1
  58. package/docs/academy/02-MasteryTrack/04-WorkWithData/07-drive-analytics.md +105 -71
  59. package/docs/academy/02-MasteryTrack/04-WorkWithData/_ARCHIVE-AnalyticsProcessorTutorial/_01-SetupBuilderEnvironment.md +22 -0
  60. package/docs/academy/02-MasteryTrack/04-WorkWithData/_ARCHIVE-AnalyticsProcessorTutorial/_02-CreateNewPowerhouseProject.md +9 -8
  61. package/docs/academy/02-MasteryTrack/04-WorkWithData/_ARCHIVE-AnalyticsProcessorTutorial/_03-GenerateAnAnalyticsProcessor.md +28 -32
  62. package/docs/academy/02-MasteryTrack/04-WorkWithData/_ARCHIVE-AnalyticsProcessorTutorial/_04-UpdateAnalyticsProcessor.md +25 -26
  63. package/docs/academy/02-MasteryTrack/04-WorkWithData/_ARCHIVE-AnalyticsProcessorTutorial/_category_.json +1 -1
  64. package/docs/academy/02-MasteryTrack/04-WorkWithData/_category_.json +7 -7
  65. package/docs/academy/02-MasteryTrack/05-Launch/01-IntroductionToPackages.md +3 -4
  66. package/docs/academy/02-MasteryTrack/05-Launch/02-PublishYourProject.md +69 -45
  67. package/docs/academy/02-MasteryTrack/05-Launch/03-SetupEnvironment.md +70 -40
  68. package/docs/academy/02-MasteryTrack/05-Launch/04-ConfigureEnvironment.md +1 -0
  69. package/docs/academy/02-MasteryTrack/05-Launch/_category_.json +7 -7
  70. package/docs/academy/02-MasteryTrack/_category_.json +6 -6
  71. package/docs/academy/03-ExampleUsecases/Chatroom/02-CreateNewPowerhouseProject.md +5 -3
  72. package/docs/academy/03-ExampleUsecases/Chatroom/03-DefineChatroomDocumentModel.md +38 -37
  73. package/docs/academy/03-ExampleUsecases/Chatroom/04-ImplementOperationReducers.md +45 -41
  74. package/docs/academy/03-ExampleUsecases/Chatroom/05-ImplementChatroomEditor.md +14 -14
  75. package/docs/academy/03-ExampleUsecases/Chatroom/06-LaunchALocalReactor.md +6 -6
  76. package/docs/academy/03-ExampleUsecases/Chatroom/_category_.json +1 -1
  77. package/docs/academy/04-APIReferences/00-PowerhouseCLI.md +104 -43
  78. package/docs/academy/04-APIReferences/01-ReactHooks.md +177 -129
  79. package/docs/academy/04-APIReferences/04-RelationalDatabase.md +121 -113
  80. package/docs/academy/04-APIReferences/05-PHDocumentMigrationGuide.md +48 -41
  81. package/docs/academy/04-APIReferences/_category_.json +6 -6
  82. package/docs/academy/05-Architecture/00-PowerhouseArchitecture.md +1 -2
  83. package/docs/academy/05-Architecture/01-WorkingWithTheReactor.md +11 -8
  84. package/docs/academy/05-Architecture/05-DocumentModelTheory/_category_.json +1 -1
  85. package/docs/academy/05-Architecture/_category_.json +6 -6
  86. package/docs/academy/06-ComponentLibrary/00-DocumentEngineering.md +25 -23
  87. package/docs/academy/06-ComponentLibrary/02-CreateCustomScalars.md +105 -93
  88. package/docs/academy/06-ComponentLibrary/03-IntegrateIntoAReactComponent.md +1 -0
  89. package/docs/academy/06-ComponentLibrary/_category_.json +7 -7
  90. package/docs/academy/07-Cookbook.md +268 -35
  91. package/docs/academy/08-Glossary.md +7 -1
  92. package/docs/bookofpowerhouse/01-Overview.md +2 -2
  93. package/docs/bookofpowerhouse/02-GeneralFrameworkAndPhilosophy.md +1 -7
  94. package/docs/bookofpowerhouse/03-PowerhouseSoftwareArchitecture.md +10 -7
  95. package/docs/bookofpowerhouse/04-DevelopmentApproaches.md +10 -4
  96. package/docs/bookofpowerhouse/05-SNOsandANewModelForOSSandPublicGoods.md +23 -30
  97. package/docs/bookofpowerhouse/06-SNOsInActionAndPlatformEconomies.md +0 -7
  98. package/docusaurus.config.ts +64 -66
  99. package/package.json +9 -7
  100. package/scripts/generate-combined-cli-docs.ts +43 -13
  101. package/sidebars.ts +2 -0
  102. package/src/components/HomepageFeatures/index.tsx +171 -78
  103. package/src/components/HomepageFeatures/styles.module.css +1 -2
  104. package/src/css/custom.css +89 -89
  105. package/src/pages/_archive-homepage.tsx +17 -16
  106. package/src/theme/DocCardList/index.tsx +9 -8
  107. package/static.json +6 -6
  108. package/tsconfig.tsbuildinfo +1 -0
@@ -1,14 +1,15 @@
1
1
  # Configure a drive
2
2
 
3
- A drive in Powerhouse is a container for documents and data. It's a place where you can organize and store your documents and share them with others. This guide walks you through configuring and managing drives in your Powerhouse environment.
3
+ A drive in Powerhouse is a container for documents and data. It's a place where you can organize and store your documents and share them with others. This guide walks you through configuring and managing drives in your Powerhouse environment.
4
4
 
5
5
  :::info **Prerequisites**
6
6
 
7
7
  Before configuring a drive, ensure you have:
8
+
8
9
  - Powerhouse [CLI installed](/academy/MasteryTrack/BuilderEnvironment/BuilderTools)
9
10
  - Access to a Powerhouse instance
10
11
  - Appropriate permissions to create and manage drives
11
- :::
12
+ :::
12
13
 
13
14
  ## Understanding drives
14
15
 
@@ -16,7 +17,7 @@ Before configuring a drive, ensure you have:
16
17
 
17
18
  A local drive is a container for local documents and data, hosted on your local machine. Technically, a drive is itself a document that contains a list of the documents inside it. When you run Connect locally with `ph connect`, a local drive is automatically added. You can also create a new local drive by clicking **'Create New Drive'** in Connect.
18
19
 
19
- ### Remote drives vs. reactors
20
+ ### Remote drives vs. reactors
20
21
 
21
22
  Remote drives in Powerhouse allow you to connect to and work with data stored in external systems or cloud services. These drives act as bridges between Powerhouse contributors or other data sources, enabling seamless data synchronization. Drives can exist in three types of locations:
22
23
 
@@ -25,23 +26,22 @@ Remote drives in Powerhouse allow you to connect to and work with data stored in
25
26
  - **Decentralized Storage**: Such as Ceramic or IPFS, enabling distributed and blockchain-based storage options.
26
27
 
27
28
  :::tip **Explainer**
28
- **Powerhouse Reactors** are the nodes in the network that store and synchronize documents and drives, resolve conflicts, and rerun operations to verify document event histories.
29
- Reactors can be configured for local storage, centralized cloud storage, or a decentralized storage network.
29
+ **Powerhouse Reactors** are the nodes in the network that store and synchronize documents and drives, resolve conflicts, and rerun operations to verify document event histories.
30
+ Reactors can be configured for local storage, centralized cloud storage, or a decentralized storage network.
30
31
 
31
32
  A reactor allows you to store multiple documents and host **drives** and Drive Explorers with different organizational purposes, users, access rights, and more.
32
33
  :::
33
34
 
34
- A drive uses a reactor and its underlying storage layer. A reactor is the low-level component that enables the synchronization of documents and drives.
35
+ A drive uses a reactor and its underlying storage layer. A reactor is the low-level component that enables the synchronization of documents and drives.
35
36
 
36
- ### Drive apps
37
+ ### Drive apps
37
38
 
38
- **Drive Explorers** (also known as Drive Apps) are specialized interfaces that enhance how users interact with documents within a drive. As mentioned, a drive is technically just another document containing a list of other documents. This means you can create a custom editor for your drive document.
39
+ **Drive Explorers** (also known as Drive Apps) are specialized interfaces that enhance how users interact with documents within a drive. As mentioned, a drive is technically just another document containing a list of other documents. This means you can create a custom editor for your drive document.
39
40
 
40
- These customized editors are called Drive Explorers or Drive Apps. They provide custom views, organization tools, and interactive features tailored to specific use cases. For example, a Drive Explorer might present data as a Kanban board, provide aggregated insights, or offer specialized widgets for data processing.
41
+ These customized editors are called Drive Explorers or Drive Apps. They provide custom views, organization tools, and interactive features tailored to specific use cases. For example, a Drive Explorer might present data as a Kanban board, provide aggregated insights, or offer specialized widgets for data processing.
41
42
 
42
43
  To learn more about building and customizing Drive Explorers, check out our [Building a Drive Explorer](/academy/MasteryTrack/BuildingUserExperiences/BuildingADriveExplorer) guide.
43
44
 
44
-
45
45
  ## Creating a new drive
46
46
 
47
47
  <figure className="image-container">
@@ -50,7 +50,8 @@ To learn more about building and customizing Drive Explorers, check out our [Bui
50
50
  </figure>
51
51
 
52
52
  To create a new drive in Powerhouse, follow these steps:
53
- 1. Click the "**Create New Drive**" button in the Connect interface or the **+** icon in the Connect sidebar.
53
+
54
+ 1. Click the "**Create New Drive**" button in the Connect interface or the **+** icon in the Connect sidebar.
54
55
  2. In the modal that appears, enter a name for your drive in the "**Drive Name**" field.
55
56
  3. Select the desired Drive App (such as the Generic Drive Explorer, or any other Drive App you've installed).
56
57
  4. Choose the location for your drive: **Local** (only available to you), **Cloud** (available to people in this drive), or **Public** (available to everyone).
@@ -62,13 +63,14 @@ To create a new drive in Powerhouse, follow these steps:
62
63
  You can also add a new remote drive to your Connect environment programmatically using GraphQL mutations. This is especially useful for automation, scripting, or integrating with external systems.
63
64
 
64
65
  :::info **Prerequisites**
65
- - Access to the Switchboard or remote reactor (server node) of your Connect instance. In your local project, you can start your Reactor by running the following command in a different terminal from Connect Studio.
66
+
67
+ - Access to the Switchboard or remote reactor (server node) of your Connect instance. In your local project, you can start your Reactor by running the following command in a different terminal from Connect Studio.
66
68
  `bash
67
- ph reactor
68
- `
69
+ ph reactor
70
+ `
69
71
  - The GraphQL endpoint of your instance. For example, for the staging environment, use: `https://staging.switchboard.phd/graphql/system` (this is a supergraph gateway. Read more about [subgraphs and supergraphs here](/academy/MasteryTrack/WorkWithData/UsingSubgraphs).
70
72
  - Appropriate permissions to perform mutations.
71
- :::
73
+ :::
72
74
 
73
75
  <figure className="image-container">
74
76
  <img src={require("./images/CreateNewDrive.png").default} alt="Create a new drive" />
@@ -76,58 +78,70 @@ You can also add a new remote drive to your Connect environment programmatically
76
78
  </figure>
77
79
 
78
80
  ### 1. **Navigate to the GraphQL Playground or use a GraphQL client**
79
- - Open [https://switchboard.phd/graphql/system](https://switchboard.phd/graphql/system) in your browser, or use a tool like [GraphQL Playground](https://www.apollographql.com/docs/apollo-server/testing/graphql-playground/).
81
+
82
+ - Open [https://switchboard.phd/graphql/system](https://switchboard.phd/graphql/system) in your browser, or use a tool like [GraphQL Playground](https://www.apollographql.com/docs/apollo-server/testing/graphql-playground/).
80
83
 
81
84
  ### 2. **Prepare the Mutation**
82
- - Use the following mutation to create a new drive:
83
-
84
- ```graphql title="Create Drive Mutation"
85
- mutation Mutation($name: String!, $icon: String, $addDriveId: String, $slug: String) {
86
- addDrive(name: $name, icon: $icon, id: $addDriveId, slug: $slug) {
87
- icon
88
- id
89
- name
90
- slug
91
- }
92
- }
93
- ```
94
-
95
- - These are the example variables, feel free to change these as you like and add a different name or logo for your drive:
96
- ```json title="Example Variables"
97
- {
98
- "name": "AcademyTest",
99
- "icon": "https://static.thenounproject.com/png/3009860-200.png",
100
- "addDriveId": null,
101
- "slug": null
102
- }
103
- ```
104
- - You can also provide a custom `id` or `slug` if needed.
85
+
86
+ - Use the following mutation to create a new drive:
87
+
88
+ ```graphql title="Create Drive Mutation"
89
+ mutation Mutation(
90
+ $name: String!
91
+ $icon: String
92
+ $addDriveId: String
93
+ $slug: String
94
+ ) {
95
+ addDrive(name: $name, icon: $icon, id: $addDriveId, slug: $slug) {
96
+ icon
97
+ id
98
+ name
99
+ slug
100
+ }
101
+ }
102
+ ```
103
+
104
+ - These are the example variables, feel free to change these as you like and add a different name or logo for your drive:
105
+
106
+ ```json title="Example Variables"
107
+ {
108
+ "name": "AcademyTest",
109
+ "icon": "https://static.thenounproject.com/png/3009860-200.png",
110
+ "addDriveId": null,
111
+ "slug": null
112
+ }
113
+ ```
114
+
115
+ - You can also provide a custom `id` or `slug` if needed.
105
116
 
106
117
  ### 3. **Execute the Mutation**
107
- - Run the mutation. On success, you will receive a response containing the new drive's `icon`, `id`, `name`, and `slug`:
108
-
109
- ```json title="Successful Response"
110
- {
111
- "data": {
112
- "addDrive": {
113
- "icon": "https://static.thenounproject.com/png/3009860-200.png",
114
- "id": "6461580b-d317-4596-942d-f6b3d1bfc8fd",
115
- "name": "AcademyTest",
116
- "slug": "6461580b-d317-4596-942d-f6b3d1bfc8fd"
117
- }
118
- }
119
- }
120
- ```
118
+
119
+ - Run the mutation. On success, you will receive a response containing the new drive's `icon`, `id`, `name`, and `slug`:
120
+
121
+ ```json title="Successful Response"
122
+ {
123
+ "data": {
124
+ "addDrive": {
125
+ "icon": "https://static.thenounproject.com/png/3009860-200.png",
126
+ "id": "6461580b-d317-4596-942d-f6b3d1bfc8fd",
127
+ "name": "AcademyTest",
128
+ "slug": "6461580b-d317-4596-942d-f6b3d1bfc8fd"
129
+ }
130
+ }
131
+ }
132
+ ```
121
133
 
122
134
  ### 4. **Construct the Drive URL**
123
- - Once you have the `id` or `slug`, you can construct the drive URL for Connect:
124
- - Format: `domain/d/<driveId>` or `domain/d/<driveSlug>`
125
- - Depending on whether you are using a hosted or a local environment, the domain in your URL will change.
126
- - Example: `https://connect.phd/d/6461580b-d317-4596-942d-f6b3d1bfc8fd`
127
- - Example: `https://localhost:4001/d/6461580b-d317-4596-942d-f6b3d1bfc8fd`
135
+
136
+ - Once you have the `id` or `slug`, you can construct the drive URL for Connect:
137
+ - Format: `domain/d/<driveId>` or `domain/d/<driveSlug>`
138
+ - Depending on whether you are using a hosted or a local environment, the domain in your URL will change.
139
+ - Example: `https://connect.phd/d/6461580b-d317-4596-942d-f6b3d1bfc8fd`
140
+ - Example: `https://localhost:4001/d/6461580b-d317-4596-942d-f6b3d1bfc8fd`
128
141
 
129
142
  ### 5. **Add the Drive in Connect**
130
- - Use the constructed URL to add or access the drive in your Connect environment via the 'Add Drive' button.
143
+
144
+ - Use the constructed URL to add or access the drive in your Connect environment via the 'Add Drive' button.
131
145
 
132
146
  <figure className="image-container">
133
147
  <img src={require("./images/AddDrive.png").default} alt="Create a new drive" />
@@ -138,11 +152,12 @@ You can also add a new remote drive to your Connect environment programmatically
138
152
 
139
153
  This approach allows you to automate drive creation and integration with other systems, making it easy to manage drives at scale.
140
154
 
141
- ## Up next
155
+ ## Up next
142
156
 
143
- You've now experienced the use of GraphQL to modify or read data captured in Powerhouse for the first time.
157
+ You've now experienced the use of GraphQL to modify or read data captured in Powerhouse for the first time.
144
158
  You can now either continue with:
145
- - User interfaces and [build a custom drive experiences](/academy/MasteryTrack/BuildingUserExperiences/BuildingADriveExplorer)
159
+
160
+ - User interfaces and [build a custom drive experiences](/academy/MasteryTrack/BuildingUserExperiences/BuildingADriveExplorer)
146
161
  - Keep playing with data and the [Switchboard API](/academy/MasteryTrack/WorkWithData/UsingTheAPI)
147
162
 
148
163
  Enjoy!