Skip to content

Commit 8e1cda8

Browse files
authored
docs: refactor README.md and update credits (#216)
1 parent 83f6fe6 commit 8e1cda8

File tree

4 files changed

+371
-19
lines changed

4 files changed

+371
-19
lines changed

CODE_OF_CONDUCT.md

Lines changed: 127 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,127 @@
1+
# Contributor covenant code of conduct
2+
3+
## Our pledge
4+
5+
We as members, contributors, and leaders pledge to make participation in our
6+
community a harassment-free experience for everyone, regardless of age, body
7+
size, visible or invisible disability, ethnicity, sex characteristics, gender
8+
identity and expression, level of experience, education, socio-economic status,
9+
nationality, personal appearance, race, religion, or sexual identity
10+
and orientation.
11+
12+
We pledge to act and interact in ways that contribute to an open, welcoming,
13+
diverse, inclusive, and healthy community.
14+
15+
## Our standards
16+
17+
Examples of behavior that contributes to a positive environment for our
18+
community include:
19+
20+
- Demonstrating empathy and kindness toward other people
21+
- Being respectful of differing opinions, viewpoints, and experiences
22+
- Giving and gracefully accepting constructive feedback
23+
- Accepting responsibility and apologizing to those affected by our mistakes,
24+
and learning from the experience
25+
- Focusing on what is best not just for us as individuals, but for the
26+
overall community
27+
28+
Examples of unacceptable behavior include:
29+
30+
- The use of sexualized language or imagery, and sexual attention or
31+
advances of any kind
32+
- Trolling, insulting or derogatory comments, and personal or political attacks
33+
- Public or private harassment
34+
- Publishing others' private information, such as a physical or email
35+
address, without their explicit permission
36+
- Other conduct which could reasonably be considered inappropriate in a
37+
professional setting
38+
39+
## Enforcement responsibilities
40+
41+
Community leaders are responsible for clarifying and enforcing our standards of
42+
acceptable behavior and will take appropriate and fair corrective action in
43+
response to any behavior that they deem inappropriate, threatening, offensive,
44+
or harmful.
45+
46+
Community leaders have the right and responsibility to remove, edit, or reject
47+
comments, commits, code, wiki edits, issues, and other contributions that are
48+
not aligned to this Code of Conduct, and will communicate reasons for moderation
49+
decisions when appropriate.
50+
51+
## Scope
52+
53+
This Code of Conduct applies within all community spaces, and also applies when
54+
an individual is officially representing the community in public spaces.
55+
Examples of representing our community include using an official e-mail address,
56+
posting via an official social media account, or acting as an appointed
57+
representative at an online or offline event.
58+
59+
## Enforcement
60+
61+
Instances of abusive, harassing, or otherwise unacceptable behavior may be
62+
reported to the community leaders responsible for enforcement.
63+
All complaints will be reviewed and investigated promptly and fairly.
64+
65+
All community leaders are obligated to respect the privacy and security of the
66+
reporter of any incident.
67+
68+
## Enforcement guidelines
69+
70+
Community leaders will follow these Community Impact Guidelines in determining
71+
the consequences for any action they deem in violation of this Code of Conduct:
72+
73+
### 1. Correction
74+
75+
**Community Impact**: Use of inappropriate language or other behavior deemed
76+
unprofessional or unwelcome in the community.
77+
78+
**Consequence**: A private, written warning from community leaders, providing
79+
clarity around the nature of the violation and an explanation of why the
80+
behavior was inappropriate. A public apology may be requested.
81+
82+
### 2. Warning
83+
84+
**Community Impact**: A violation through a single incident or series
85+
of actions.
86+
87+
**Consequence**: A warning with consequences for continued behavior. No
88+
interaction with the people involved, including unsolicited interaction with
89+
those enforcing the Code of Conduct, for a specified period of time. This
90+
includes avoiding interactions in community spaces as well as external channels
91+
like social media. Violating these terms may lead to a temporary or
92+
permanent ban.
93+
94+
### 3. Temporary ban
95+
96+
**Community Impact**: A serious violation of community standards, including
97+
sustained inappropriate behavior.
98+
99+
**Consequence**: A temporary ban from any sort of interaction or public
100+
communication with the community for a specified period of time. No public or
101+
private interaction with the people involved, including unsolicited interaction
102+
with those enforcing the Code of Conduct, is allowed during this period.
103+
Violating these terms may lead to a permanent ban.
104+
105+
### 4. Permanent ban
106+
107+
**Community Impact**: Demonstrating a pattern of violation of community
108+
standards, including sustained inappropriate behavior, harassment of an
109+
individual, or aggression toward or disparagement of classes of individuals.
110+
111+
**Consequence**: A permanent ban from any sort of public interaction within
112+
the community.
113+
114+
## Attribution
115+
116+
This Code of Conduct is adapted from the [Contributor Covenant][homepage],
117+
version 2.0, available at
118+
https://www.contributor-covenant.org/version/2/0/code_of_conduct.html.
119+
120+
Community Impact Guidelines were inspired by [Mozilla's code of conduct
121+
enforcement ladder](https://github.com/mozilla/diversity).
122+
123+
[homepage]: https://www.contributor-covenant.org
124+
125+
For answers to common questions about this code of conduct, see the FAQ at
126+
https://www.contributor-covenant.org/faq. Translations are available at
127+
https://www.contributor-covenant.org/translations.

apps/omega/CONTRIBUTIND.md

Lines changed: 217 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,217 @@
1+
# Contributing to UI-TARS Desktop
2+
3+
<!-- FIXME: Refine for Agent TARS's new structure -->
4+
5+
First off, thanks for taking the time to contribute! ❤️
6+
7+
All types of contributions are encouraged and valued. Please make sure to read the relevant section before making your contribution. It will make it a lot easier for us maintainers and smooth out the experience for all involved. The community looks forward to your contributions. 🎉
8+
9+
> And if you like the project, but just don't have time to contribute, that's fine. There are other easy ways to support the project and show your appreciation, which we would also be very happy about:
10+
> - Star the project
11+
> - Tweet about it
12+
> - Refer this project in your project's readme
13+
> - Mention the project at local meetups and tell your friends/colleagues
14+
15+
16+
## I Have a Question / Bug Report
17+
18+
> If you want to ask a question or report a bug, we assume that you have read the available Documentation.
19+
20+
Before you ask a question, it is best to search for existing [Issues](https://github.com/bytedance/ui-tars-desktop/issues) that might help you. In case you have found a suitable issue and still need clarification, you can write your question in this issue. It is also advisable to search the internet for answers first.
21+
22+
If you then still feel the need to ask a question and need clarification, we recommend the following:
23+
24+
- Open an [Issue](https://github.com/bytedance/ui-tars-desktop/issues/new).
25+
- Provide as much context as you can about what you're running into.
26+
- Provide project and platform versions (nodejs, npm, etc), depending on what seems relevant.
27+
28+
We will then take care of the issue as soon as possible.
29+
30+
## I Want To Contribute
31+
32+
### Prerequisites
33+
34+
- [Node.js](https://nodejs.org/en/download/) >= 20
35+
- [pnpm](https://pnpm.io/installation) >= 9
36+
37+
#### Technology Stack
38+
39+
This is a [Monorepo](https://pnpm.io/workspaces) project including the following technologies:
40+
41+
- Cross-platform framework: [Electron](https://www.electronjs.org/)
42+
- Interface:
43+
- [React](https://react.dev/)
44+
- [Vite](https://vitejs.dev/)
45+
- [Chakra UI V2](https://v2.chakra-ui.com/)
46+
- State management and communication:
47+
- [Zustand](https://zustand.docs.pmnd.rs/)
48+
- [@ui-tars/electron-ipc](https://github.com/bytedance/ui-tars-desktop/tree/main/packages/electron-ipc)
49+
- Automation framework/toolkit:
50+
- [nut.js](https://nutjs.dev/)
51+
- Test framework
52+
- [Vitest](https://vitest.dev/)
53+
- [Playwright](https://playwright.dev/)
54+
55+
### Structure of the project
56+
57+
```bash
58+
.
59+
├── README.md
60+
├── apps
61+
│   ├── omega
62+
│   │   ├── src
63+
│   │   │   ├── main
64+
│   │   │   ├── preload
65+
│   │   │   ├── renderer
66+
│   │   │   └── vendor
67+
│   └── ui-tars
68+
│      └── src
69+
│        ├── main
70+
│         ├── preload
71+
│         └── renderer
72+
│ 
73+
├── packages
74+
│   ├── agent-infra
75+
│   │   ├── browser
76+
│   │   ├── browser-use
77+
│   │   ├── logger
78+
│   │   ├── mcp-client
79+
│   │   ├── mcp-servers
80+
│   │   ├── search
81+
│   │   └── shared
82+
│   ├── common
83+
│   │   ├── configs
84+
│   │   └── electron-build
85+
│   └── ui-tars
86+
│   ├── action-parser
87+
│   ├── cli
88+
│   ├── electron-ipc
89+
│   ├── operators
90+
│   ├── sdk
91+
│   ├── shared
92+
│   ├── tsconfig.node.json
93+
│   ├── utio
94+
│   └── visualizer
95+
└── vitest.*.mts # Unit test configuration
96+
```
97+
98+
> **Note**: The `src` directory is located in the top-level directory instead of the `apps/{main,preload,renderer}` directories because Electron Forge previously did not support Pnpm's hoisting mechanism([electron/forge#2633](https://github.com/electron/forge/issues/2633)), requiring the `src` directory to be placed in the top-level directory.
99+
100+
101+
#### Clone the repository
102+
103+
```bash
104+
$ git clone https://github.com/bytedance/ui-tars-desktop.git
105+
$ cd ui-tars-desktop
106+
```
107+
108+
### Development
109+
110+
#### Install dependencies
111+
112+
```bash
113+
$ pnpm install
114+
```
115+
116+
#### Run the application
117+
118+
```bash
119+
$ pnpm run dev:ui-tars # Start UI-TARS Desktop
120+
$ pnpm run dev:agent-tars # Start Agent-TARS Desktop
121+
```
122+
123+
After the application starts, you can see the UI-TARS interface within the application.
124+
125+
> **Note**: On MacOS, you need to grant permissions to the app (e.g., iTerm2, Terminal) you are using to run commands.
126+
127+
#### Main process reload
128+
129+
By default, `pnpm run dev` only has frontend Hot Module Replacement (HMR) hot updates. If you need to simultaneously reload the main process during debugging, you can execute `pnpm run dev:w`.
130+
131+
```bash
132+
$ pnpm run dev:w
133+
```
134+
135+
#### Building
136+
137+
Run `pnpm run build` in current system, it will output into `out/*` directory.
138+
139+
To build the products of other systems, run:
140+
- Mac x64: `pnpm run publish:mac-x64`
141+
- Mac ARM: `pnpm run publish:mac-arm64`
142+
- Windows x64: `pnpm run publish:win32`
143+
- Windows ARM: `pnpm run publish:win32-arm64`
144+
145+
### Release
146+
147+
#### Desktop Application
148+
149+
The CI pipeline to execute is [.github/workflows/release.yml](.github/workflows/release.yml), only manual triggered by maintainers. If you're a maintainer, you can follow the steps below to release the application:
150+
151+
1. Edit the `version` in `package.json`
152+
2. Git commit and push to the `release/${version}` branch, create a PR targeting `main` branch, titled `release(app): ${version}`
153+
3. Trigger the release [workflow](https://github.com/bytedance/UI-TARS-desktop/actions/workflows/release.yml) manually after the PR is merged
154+
155+
Currently, the release workflow supports the following platforms:
156+
157+
- MacOS x64
158+
- MacOS arm64
159+
- Windows x64
160+
161+
#### Packages
162+
163+
##### Latest version
164+
165+
If you want to publish the `latest` version packages to the npm registry, you can run the following command:
166+
167+
1. `pnpm changeset` to specify the changelogs for the packages you want to publish
168+
2. Git commit and push to the `release-pkgs/${version}` branch, create a PR targeting `main` branch, titled `release(pkgs): ${version}`
169+
3. `pnpm run publish:packages` to publish the packages in latest `origin/main` branch after the PR is merged
170+
171+
##### Beta version
172+
173+
If you want to publish the `beta` version packages to the npm registry, you can run the following command:
174+
175+
1. `pnpm changeset` to specify the changelogs for the packages you want to publish
176+
2. Git commit and push to the branch
177+
3. `pnpm run publish-beta:packages` to publish the packages in current branch
178+
179+
180+
### Documentation
181+
182+
The documents are placed in the `docs/*.md` directory, formatted in markdown. There is currently no documentation site, but the `docs/*.md` directory will be converted into a documentation site in the future.
183+
184+
## Styleguides
185+
186+
### Pre-commit Hooks
187+
188+
We use [Husky](https://typicode.github.io/husky/#/) and [lint-staged](https://github.com/okonet/lint-staged) to enforce the pre-commit hooks. The hooks include:
189+
190+
- `prettier --write` to format the code
191+
- `npm run typecheck` to strictly check the type
192+
193+
### Commit Messages
194+
195+
We use [Conventional Commits](https://www.conventionalcommits.org/) to standardize the commit messages.
196+
197+
### CI / Testing
198+
199+
Each PR or main branch push will trigger the CI pipeline to run the unit test and E2E test.
200+
201+
#### Unit test
202+
203+
```bash
204+
pnpm run test
205+
```
206+
207+
#### E2E test
208+
209+
```bash
210+
pnpm run test:e2e
211+
```
212+
213+
## Submitting Changes
214+
215+
* Push your changes to a feature branch in your fork of the repository.
216+
* Submit a pull request to this repository
217+
* Accept the CLA in your PR.

0 commit comments

Comments
 (0)