
# Kohaku Software License 1.0

**Published by KohakuBlueLeaf**

## Purpose

The **Kohaku Software License** aims to provide maximum freedom for users to work with the Software while protecting contributors from liability and ensuring the freedom of end users. It incorporates commercial usage restrictions to balance open access with sustainable development.

## Definitions

- **Software**: Refers to the source code, compiled binaries, libraries, modules, documentation, configuration files, and any other materials provided under this License.

- **Source Code**: The preferred form for making modifications to the Software, including all source files, build scripts, configuration files, and documentation necessary to understand, compile, and modify the Software.

- **Derivative Work**: Any software based on or derived from the original Software, including but not limited to:
  - Modified versions of the Software
  - Software that incorporates any portion of the Software
  - Software that links to, imports, or otherwise depends on the Software in a manner that creates a combined work

  For a Derivative Work to qualify under this license, it must include the complete Source Code necessary to build, use, and modify the Derivative Work.

- **Modify**: To alter, adapt, translate, or otherwise change the Software, or to create Derivative Works.

- **Service Provider**: An entity that uses the Software to offer services to **End Users**, thereby making the **End Users** the recipients of the service.

- **End User**: Any individual or entity that uses the Software directly or uses services provided by a **Service Provider** that utilizes the Software.

- **Non-Commercial Purpose**: Uses that do not involve direct or indirect monetary compensation arising from the use of the Software, including personal use, academic research, experimentation, testing, or non-commercial organizational use.

- **Commercial Usage**: Any use of the Software where:
  - The Software is used to provide services or products to customers, clients, or users (internal or external) for monetary compensation, or
  - The Software is incorporated into commercial products or services, or
  - The Software is used as part of internal company systems that help internal teams execute their business operations in a for-profit organization, or
  - The organization using the Software generates revenue from activities directly or indirectly involving the Software

- **Total Revenue**:
  - For Service Providers: The total revenue generated from services utilizing the Software
  - For product vendors: The total revenue from products incorporating the Software
  - For internal business systems: The total revenue of the organization using the Software for business operations

## License Grant

### 1. General Permissions

Subject to compliance with this License, KohakuBlueLeaf grants you a non-exclusive, worldwide, non-transferable, non-sublicensable, revocable, royalty-free, and limited license to access, use, modify, create Derivative Works, and distribute the Software for **Non-Commercial Purposes** and **Commercial Usage** under certain conditions.

### 2. Categories of Use

#### a. Direct Users

Individuals or entities that use the Software directly for their personal, academic, or non-commercial purposes without operating in a commercial capacity.

#### b. Service Providers and Commercial Entities

Entities that use the Software to offer services or products to **End Users**, or that use the Software for internal business operations in a for-profit organization.

### 3. Source Code Availability

When using or distributing the Software or any Derivative Works, you must:

- Make the complete Source Code available to recipients
- Ensure the Source Code is in a form that allows recipients to build, modify, and use the Software
- Include all necessary build scripts, configuration files, and dependencies information

### 4. Derivative Works

Any Derivative Works created must be published under the **Kohaku Software License**. The minimal requirement includes:

- Complete Source Code of the Derivative Work
- Build and installation instructions
- Clear indication of what has been modified from the original Software

**Additional Requirements for Combined Works:**

- If the Derivative Work combines multiple software components or libraries, all such components that form a combined work must be published under this License or a compatible license.
- You must provide clear documentation on how the components interact and how to build the combined work.
- **Note**: You are not obligated to release proprietary business logic or workflows that use the Software through standard APIs or interfaces without creating Derivative Works.

## Restrictions

### 1. Commercial Usage

- **Definition**: **Commercial Usage** is defined as any use where:
  - The Software is used to provide services or products to customers, clients, or users (internal or external) for monetary compensation
  - The Software is incorporated into commercial products or services
  - The Software is used as part of internal company systems that help internal teams execute their business operations in a for-profit organization
  - The organization using the Software generates revenue from activities directly or indirectly involving the Software

- **Conditions for Requiring a Commercial License**: Commercial Usage is prohibited **if either** of the following conditions are met:
  - **Total Revenue** attributable to or associated with the Software exceeds $25,000 USD per year, OR
  - **Usage Duration** exceeds 3 months

- **Revenue Threshold and Usage Duration**:
  - **Trial Period**: Entities are allowed to engage in **Commercial Usage** without a commercial license for a trial period of **up to 3 months**, provided their **Total Revenue** remains below or equal to $25,000 USD per year.
  - **Revenue Limit**: Entities with **Total Revenue** attributable to or associated with the Software below or equal to $25,000 USD per year are permitted to continue **Commercial Usage** without a commercial license, provided the **Usage Duration** does not exceed 3 months.
  - **Exceeding Either Threshold**: If an entity's **Total Revenue** exceeds $25,000 USD per year OR the **Commercial Usage** period exceeds 3 months, the entity must request a commercial license from the author.

- **Requesting a Commercial License**: Entities that need to engage in **Commercial Usage** exceeding both thresholds must contact the author at kohaku@kblueleaf.net to request a commercial license. The author may grant such licenses at their sole discretion, potentially subject to fees, royalties, or revenue-sharing agreements.

### 2. Prohibited Uses

You may not use the Software for:

- Military purposes or weapons development
- Surveillance systems or mass monitoring
- Biometric identification or tracking systems
- Any activity that infringes on third-party rights
- Any use violating applicable laws, including privacy and security regulations
- Generating or distributing malware, exploits, or other malicious software

You may not:

- Alter or remove copyright and proprietary notices
- Circumvent or remove any security or usage restrictions
- Impose additional terms that conflict with this License
- Distribute the Software to prohibited individuals, entities, or countries as defined by applicable export laws

### 3. Distribution Requirements

When distributing the Software or any Derivative Works, you must:

- Include a copy of this License with the distribution
- Include the complete Source Code or provide clear instructions on how to obtain it
- **Attribution Notice**: Prominently display the following notice:

  ```
  This Software is licensed under the Kohaku Software License by KohakuBlueLeaf.
  Copyright 2025 KohakuBlueLeaf.

  IN NO EVENT SHALL KohakuBlueLeaf BE LIABLE FOR ANY CLAIM, DAMAGES, OR OTHER
  LIABILITY ARISING FROM THE USE OF THIS SOFTWARE.
  ```

- **For Derivative Works**:
  - Include a statement clearly indicating that you have modified the original Software
  - Document the nature of modifications made
  - Ensure all Source Code is available under this License

- **No Misrepresentation**: Do not misrepresent or imply that Derivative Works are official versions or have been endorsed by the original author unless authorized in writing.

- **Service Provider Requirements**:
  - **Service Providers** must provide **End Users** with clear notice that the service utilizes Software licensed under the Kohaku Software License
  - Include a reference to the original Software and this License in service documentation, terms of service, or user interface (e.g., "About" page, footer)

## No Harm and No Liability

### 1. No Harm

You agree that no contributor's conduct in creating the Software has caused you harm. To the extent permitted by law, you waive the right to pursue any legal claims against contributors related to the creation of the Software.

### 2. No Liability

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES, OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT, OR OTHERWISE, ARISING FROM, OUT OF, OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

## Patent Grant

Each contributor grants you a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable patent license to make, use, offer to sell, sell, import, and otherwise transfer the Software, where such license applies only to those patent claims licensable by such contributor that are necessarily infringed by their contribution(s) alone or by combination of their contribution(s) with the Software.

## Interpretation of Ambiguous Terms

In the event of any ambiguity or uncertainty in the interpretation of the terms of this License, the Licensee has the right to interpret the ambiguous descriptions in a manner that aligns with the intended purpose of this License, which is to promote open access while protecting sustainable development through commercial licensing.

## Acceptance and Compliance

By using, modifying, or distributing the Software, you agree to comply with all terms of this License. Non-compliance may result in the automatic termination of your rights under this License.

## Termination

Your rights under this License terminate automatically upon any breach of its terms. Upon termination, you must:

- Cease all use, modification, and distribution of the Software and Derivative Works
- Destroy all copies of the Software in your possession or control
- If you are a Service Provider, cease providing services that utilize the Software

Sections regarding No Liability, Indemnification, and General Provisions survive termination.

## Indemnification

You agree to indemnify, defend, and hold harmless KohakuBlueLeaf and its affiliates, contributors, and licensors from and against any claims, damages, losses, liabilities, costs, and expenses (including reasonable attorneys' fees) arising from:

- Your use of the Software
- Your violation of this License
- Your violation of any rights of another party
- Your distribution of the Software or Derivative Works

## General Provisions

- **Governing Law**: This License is governed by the laws of Taiwan, without regard to conflict of law principles.

- **Severability**: If any provision of this License is held to be unenforceable or invalid, that provision shall be modified to the minimum extent necessary to make it enforceable, and the remaining provisions shall remain in full force and effect.

- **Entire Agreement**: This License constitutes the entire agreement between you and KohakuBlueLeaf regarding the Software and supersedes all prior agreements and understandings.

- **No Waiver**: The failure of KohakuBlueLeaf to enforce any provision of this License shall not constitute a waiver of that provision or any other provision.

- **Assignment**: You may not assign or transfer your rights or obligations under this License without prior written consent from KohakuBlueLeaf.

## Revisions

KohakuBlueLeaf may publish revised versions of the Kohaku Software License from time to time. Each version will be given a distinguishing version number. You may choose to use the Software under the terms of the version of the License under which you originally received the Software, or under the terms of any subsequent version published by KohakuBlueLeaf.

## Contact

For commercial licensing inquiries, please contact: kohaku@kblueleaf.net
