Licensing
Relevant source files
The following files were used as context for generating this wiki page:
The Dyad project operates under a mixed-licensing model. This includes a specific commercial license for "Pro" features, while also incorporating third-party components that are governed by their own open-source licenses, such as Apache 2.0. The distinction between different feature sets, such as "Pro" and standard versions, is managed within the application's logic by loading different system prompts and enabling specific functionalities based on the user's tier.
Dyad Pro License
The "Pro" version of Dyad is governed by the "Dyad Pro License", a commercial license agreement between Dyad (the "Licensor") and the user (the "Licensee"). This license grants specific rights for using the software in exchange for payment of license fees.
Sources: src/pro/LICENSE
Key Terms and Conditions
The following table summarizes the main permissions, limitations, and conditions outlined in the Dyad Pro License.
| Category | Provision | Description |
|---|---|---|
| Grant of License | Usage Rights | The Licensee is granted a non-exclusive, non-transferable right to use the software for internal business purposes. This includes the right to make and use a reasonable number of copies. |
| Derivative Works | The Licensee may create derivative works of the software, but only for their own internal use. | |
| Limitations | Distribution | The Licensee is expressly prohibited from distributing, sublicensing, renting, or leasing the software to any third party. |
| Service Provision | The software cannot be used for service bureau, timesharing, or other services where it is made available to third parties. | |
| Reverse Engineering | Reverse engineering, decompiling, or disassembling the software is forbidden, except where permitted by applicable law. | |
| Conditions | Fees & Payment | The license is contingent upon the payment of all applicable fees. |
| Termination | The license terminates automatically if the Licensee fails to comply with its terms. The Licensor can also terminate the license with written notice upon a material breach. | |
| Warranty & Liability | The software is provided "AS IS" without any warranty. The Licensor's liability is limited to the fees paid by the Licensee in the 12 months preceding the claim. |
Sources: src/pro/LICENSE
This diagram illustrates the relationship between the Licensor, Licensee, and the software under the Pro license.
Sources: src/pro/LICENSE
Third-Party Licenses
Dyad incorporates code from other projects, which are subject to their own licensing terms. It is important to adhere to these licenses when using or modifying the corresponding parts of the Dyad codebase.
Apache 2.0 License (from code-panda)
The system prompt for Supabase integration is based on content from the code-panda project, which is licensed under the Apache License 2.0.
System prompt based on https://github.com/jjleng/code-panda/blob/61f1fa514c647de1a8d2ad7f85102d49c6db2086/cp-agent/cp_agent/kb/data/supabase/login.txt
which is Apache 2.0 licensed and copyrighted to Jijun Leng
This means that the specific content within src/prompts/supabase_prompt.ts derived from code-panda is subject to the terms of the Apache 2.0 license, which generally allows for use, modification, and distribution, provided that proper attribution is maintained.
Sources: src/prompts/supabase_prompt.ts:2-4
Feature Gating and Licensing Tiers
The application's architecture includes logic to serve different system prompts and enable features based on the user's "chat mode" or license tier. This is a common pattern for managing features between standard and pro versions.
Prompt Selection Logic
The constructSystemPrompt and getSystemPromptForChatMode functions are central to this mechanism. They select and construct the appropriate system prompt based on the chatMode and whether Pro features like enableTurboEditsV2 are active.
The following flowchart shows how a system prompt is selected:
This logic allows the system to tailor its capabilities, such as code generation (build mode), conceptual explanation (ask mode), or advanced editing (enableTurboEditsV2), which likely correspond to different license tiers.
Sources: src/prompts/system_prompt.ts:506-524
Pro vs. Non-Pro Features
The codebase contains hints of features that are gated based on the user's license. For example, the enableTurboEditsV2 flag is explicitly checked to append the TURBO_EDITS_V2_SYSTEM_PROMPT, indicating an advanced editing feature available in the Pro version.
Additionally, test snapshots for non-pro scenarios show specific system prompt configurations. For instance, a prompt for a non-pro user who mentions another app includes the following text:
The referenced apps are NOT part of the current app and are READ-ONLY.
This suggests that while referencing other apps is possible, the ability to edit them might be a Pro feature, and the system's behavior is adjusted accordingly for non-pro users.
Sources: src/prompts/system_prompt.ts:521-522, e2e-tests/snapshots/mention_app.spec.ts_mention-app-without-pro-1.txt