Skip to content

Commit d156e4f

Browse files
authored
Merge pull request #231 from httpsphl/feat/catalog-legal-roles
feat(catalog): seven legal roles
2 parents 4a53cac + c98fd73 commit d156e4f

24 files changed

Lines changed: 499 additions & 9 deletions

‎app/src/features/catalog/AgencyGrid.tsx‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ const CATEGORIES: Category[] = [
2929
"finance",
3030
"people",
3131
"security",
32+
"legal",
3233
];
3334

3435
/** A fixed color per role, so the mascots tell the cards apart. */

‎app/src/features/catalog/agency.test.tsx‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ describe("the Bot agency", () => {
3333

3434
fireEvent.click(within(invite).getByRole("button", { name: "See all bots" }));
3535
const dialog = await screen.findByRole("dialog", { name: "Bot agency" });
36-
expect(await within(dialog).findAllByRole("listitem")).toHaveLength(108);
36+
expect(await within(dialog).findAllByRole("listitem")).toHaveLength(115);
3737
});
3838

3939
test("a crew with only its chief invites the owner to pick bots, and a click adds one", async () => {
@@ -82,7 +82,7 @@ describe("the Bot agency", () => {
8282
await openCrewWithChief();
8383
fireEvent.click(screen.getByRole("button", { name: "Bot agency" }));
8484
const dialog = await screen.findByRole("dialog", { name: "Bot agency" });
85-
expect(await within(dialog).findAllByRole("listitem")).toHaveLength(108);
85+
expect(await within(dialog).findAllByRole("listitem")).toHaveLength(115);
8686

8787
fireEvent.click(within(dialog).getByRole("button", { name: "Marketing & sales" }));
8888
expect(within(dialog).getAllByRole("listitem")).toHaveLength(24);
@@ -129,7 +129,7 @@ describe("the Bot agency", () => {
129129
expect(addCalls(fake)[0]).toMatchObject({ templateId: "code-reviewer" });
130130

131131
fireEvent.click(within(dialog).getByRole("button", { name: "Back to all bots" }));
132-
expect(within(dialog).getAllByRole("listitem")).toHaveLength(108);
132+
expect(within(dialog).getAllByRole("listitem")).toHaveLength(115);
133133
});
134134

135135
test("the same role twice gets another name", async () => {

‎app/src/i18n/en/catalog.ts‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ import { design } from "./catalogDesign";
44
import { engineering } from "./catalogEngineering";
55
import { engineeringMore } from "./catalogEngineeringMore";
66
import { finance } from "./catalogFinance";
7+
import { legal } from "./catalogLegal";
78
import { marketing } from "./catalogMarketing";
89
import { paidMedia } from "./catalogPaidMedia";
910
import { people } from "./catalogPeople";
@@ -40,6 +41,7 @@ export const catalog = {
4041
finance: "Finance",
4142
people: "People & HR",
4243
security: "Security",
44+
legal: "Legal",
4345
},
4446
none: "No bot matches that.",
4547
loading: "Loading the bots…",
@@ -72,5 +74,6 @@ export const catalog = {
7274
...engineeringMore,
7375
...security,
7476
...sectors,
77+
...legal,
7578
},
7679
};

‎app/src/i18n/en/catalogLegal.ts‎

Lines changed: 74 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,74 @@
1+
// Legal roles (spec 26.3): what the owner reads about each. None is a
2+
// lawyer; each says so and sends the owner to one for anything that matters.
3+
4+
export const legal = {
5+
"contract-reader": {
6+
name: "Contract Reader",
7+
role: "Reads a contract in plain words: what each side must do, the dates and money, the risky clauses and the questions to ask a lawyer",
8+
summary: "Reads a contract in plain words and flags the risky clauses and what to ask a lawyer",
9+
about:
10+
"Reads the whole contract and gives you one page: who must do what, the money, the dates and how it ends. It flags the clauses that deserve attention, such as automatic renewal, penalties or giving up rights, and marks each as common, unusual or worth negotiating. It never says a clause is valid or enforceable. It is not a lawyer, and it ends with the questions to take to one.",
11+
when: "Before you sign a contract, or when you want to understand one you already signed.",
12+
pairs: "Contract Dates Tracker, for the dates, and Legal Research Assistant.",
13+
},
14+
"terms-drafter": {
15+
name: "Terms and Privacy Notice Drafter",
16+
role: "Drafts the terms of use and the privacy notice of a site or app in plain words, from how the business really works, for a lawyer to check",
17+
summary:
18+
"Drafts your site's terms and privacy notice in plain words from how you really work, for a lawyer to check",
19+
about:
20+
"Asks how your business really works and what data it collects, then drafts the terms of use, the privacy notice and the refund and shipping policy in short, plain sentences. The parts that depend on the law are marked as questions for a lawyer, and it lists the promises you will have to keep. It never publishes anything on your site.",
21+
when: "When you launch a site, an app or a shop and need the texts that go with it.",
22+
pairs: "Privacy Engineer, for the data map, and Editor, to polish.",
23+
},
24+
"legal-research-assistant": {
25+
name: "Legal Research Assistant",
26+
role: "Finds and explains the laws, rules and decisions on a question from official sources, with exact citations, and says what it could not verify",
27+
summary:
28+
"Finds the laws and decisions on a question from official sources, with exact citations and honest limits",
29+
about:
30+
"Needs the place, the date and the facts, then looks in official sources first, opens every source before it cites it and gives you a short memo with exact references. It separates what the law says from what courts say about it and what is unsettled. It never invents a law or a case, and says when it could not verify one.",
31+
when: "When you need to know what the law says on a question, before you talk to a lawyer.",
32+
pairs: "Fact Checker, to verify a citation, and Editor, to polish the memo.",
33+
},
34+
"legal-intake-assistant": {
35+
name: "Client Intake Assistant",
36+
role: "Helps a small law practice or advisor collect a new client's facts: a clear questionnaire, a neat summary of the matter and the missing documents",
37+
summary:
38+
"Helps a small practice collect a new client's facts: a clear questionnaire, a neat summary and what is missing",
39+
about:
40+
"Prepares a plain intake form for the kind of matter, then turns the client's answers into a timeline and a one-page summary, with facts kept apart from opinions. It lists the missing documents and puts anything urgent on top. It never tells a client their rights or whether they have a case, and never contacts a client.",
41+
when: "At the first step with a new client, before the lawyer reviews the matter.",
42+
pairs: "Time and Billing Assistant, and Contract Reader.",
43+
},
44+
"legal-billing-assistant": {
45+
name: "Time and Billing Assistant",
46+
role: "Turns your work log into clear time entries and invoice drafts for a practice or consultant, and shows what is unbilled",
47+
summary:
48+
"Turns your work log into clear time entries and invoice drafts, and shows what is still unbilled",
49+
about:
50+
"Turns your notes and calendar into time entries with descriptions a client would understand and that do not reveal more than they need to. It shows what is unbilled by client, flags entries that look wrong without changing them and prepares the invoice draft from the entries you approve. It never rounds up or overstates the work.",
51+
when: "When you bill by the hour and the time slips away before you invoice.",
52+
pairs: "Invoicing Assistant, for payment follow-up, and Bookkeeper.",
53+
},
54+
"contract-deadline-tracker": {
55+
name: "Contract Dates Tracker",
56+
role: "Keeps track of the dates in your contracts: renewals, notice periods, payments and deadlines, and warns you well before each one",
57+
summary:
58+
"Keeps track of the dates in your contracts, such as renewals and notice periods, and warns you early",
59+
about:
60+
"Reads your contracts and lists every date and duty with the clause it comes from, working out the real date and saying in plain words how it was counted. It puts the traps first, such as automatic renewals with a notice period, and warns you early. If a clause is unclear it says so instead of guessing. It never sends a notice or ends a contract.",
61+
when: "When you have several contracts and are afraid of missing a renewal or a notice.",
62+
pairs: "Contract Reader, to explain a clause, and Writer, to draft a notice for you to send.",
63+
},
64+
"complaint-letter-drafter": {
65+
name: "Complaint Letter Drafter",
66+
role: "Drafts clear, firm and polite letters for a complaint or a dispute with a company or a landlord, from the facts and the papers you have",
67+
summary:
68+
"Drafts clear, firm and polite complaint letters for a dispute with a company or a landlord",
69+
about:
70+
"Gets the facts straight with you, builds a timeline checked against your papers and drafts a short, polite and firm letter: what happened, what you ask for and a reasonable date to reply. It does not threaten or exaggerate. It lists the attachments and the places to check next as questions for your country. You send the letter.",
71+
when: "When a company, a landlord or a seller has not done right by you.",
72+
pairs: "Contract Reader, for the terms, and Editor, to proofread.",
73+
},
74+
};

‎app/src/i18n/es/catalog.ts‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ import { design } from "./catalogDesign";
55
import { engineering } from "./catalogEngineering";
66
import { engineeringMore } from "./catalogEngineeringMore";
77
import { finance } from "./catalogFinance";
8+
import { legal } from "./catalogLegal";
89
import { marketing } from "./catalogMarketing";
910
import { paidMedia } from "./catalogPaidMedia";
1011
import { people } from "./catalogPeople";
@@ -37,6 +38,7 @@ export const catalog: Messages["catalog"] = {
3738
finance: "Finanzas",
3839
people: "Personas y RR. HH.",
3940
security: "Seguridad",
41+
legal: "Jurídico",
4042
},
4143
none: "Ningún bot coincide con eso.",
4244
loading: "Cargando los bots…",
@@ -69,5 +71,6 @@ export const catalog: Messages["catalog"] = {
6971
...engineeringMore,
7072
...security,
7173
...sectors,
74+
...legal,
7275
},
7376
};

‎app/src/i18n/es/catalogLegal.ts‎

Lines changed: 77 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,77 @@
1+
import type { legal as en } from "../en/catalogLegal";
2+
3+
export const legal: typeof en = {
4+
"contract-reader": {
5+
name: "Lector de contratos",
6+
role: "Lee un contrato en palabras sencillas: qué debe hacer cada parte, las fechas y el dinero, las cláusulas arriesgadas y las preguntas para un abogado",
7+
summary:
8+
"Lee un contrato en palabras sencillas y señala las cláusulas arriesgadas y qué preguntar a un abogado",
9+
about:
10+
"Lee el contrato entero y te da una página: quién debe hacer qué, el dinero, las fechas y cómo termina. Señala las cláusulas que merecen atención, como renovación automática, penalizaciones o renuncia de derechos, y marca cada una como común, inusual o que vale la pena negociar. Nunca dice que una cláusula es válida o exigible. No es abogado y termina con las preguntas para llevar a uno.",
11+
when: "Antes de firmar un contrato, o cuando quieres entender uno que ya firmaste.",
12+
pairs:
13+
"Control de plazos de contratos, para las fechas, y Asistente de investigación jurídica.",
14+
},
15+
"terms-drafter": {
16+
name: "Redactor de términos y privacidad",
17+
role: "Redacta los términos de uso y el aviso de privacidad de un sitio o app en palabras sencillas, según cómo funciona de verdad el negocio, para que un abogado los revise",
18+
summary:
19+
"Redacta los términos y el aviso de privacidad de tu sitio en palabras sencillas, para que un abogado los revise",
20+
about:
21+
"Pregunta cómo funciona de verdad tu negocio y qué datos recoge, y luego redacta los términos de uso, el aviso de privacidad y la política de cambios y envíos en frases cortas y sencillas. Los pasajes que dependen de la ley quedan como preguntas para un abogado, y lista las promesas que tendrás que cumplir. Nunca publica nada en tu sitio.",
22+
when: "Cuando lanzas un sitio, una app o una tienda y necesitas los textos que la acompañan.",
23+
pairs: "Ingeniero de privacidad, para el mapa de datos, y Corrector de textos, para pulir.",
24+
},
25+
"legal-research-assistant": {
26+
name: "Asistente de investigación jurídica",
27+
role: "Encuentra y explica las leyes, normas y decisiones sobre una cuestión en fuentes oficiales, con citas exactas, y dice qué no pudo verificar",
28+
summary:
29+
"Encuentra las leyes y decisiones sobre una cuestión en fuentes oficiales, con citas exactas y límites honestos",
30+
about:
31+
"Necesita el lugar, la fecha y los hechos, y luego busca primero en fuentes oficiales, abre cada fuente antes de citarla y te entrega un memorando corto con referencias exactas. Separa lo que dice la ley de lo que dicen los tribunales sobre ella y de lo que sigue abierto. Nunca inventa una ley ni un caso, y dice cuando no pudo verificar uno.",
32+
when: "Cuando necesitas saber qué dice la ley sobre una cuestión, antes de hablar con un abogado.",
33+
pairs:
34+
"Verificador de datos, para comprobar una cita, y Corrector de textos, para pulir el memorando.",
35+
},
36+
"legal-intake-assistant": {
37+
name: "Asistente de admisión de clientes",
38+
role: "Ayuda a un pequeño despacho o asesor a reunir los hechos de un cliente nuevo: un cuestionario claro, un resumen ordenado del asunto y los documentos que faltan",
39+
summary:
40+
"Ayuda a un pequeño despacho a reunir los hechos de un cliente nuevo: cuestionario claro, resumen ordenado y lo que falta",
41+
about:
42+
"Prepara un formulario sencillo para el tipo de asunto y luego convierte las respuestas del cliente en una línea de tiempo y un resumen de una página, con los hechos separados de las opiniones. Lista los documentos que faltan y pone lo urgente arriba. Nunca dice al cliente cuáles son sus derechos ni si tiene un caso, y nunca lo contacta.",
43+
when: "En el primer paso con un cliente nuevo, antes de que el abogado revise el asunto.",
44+
pairs: "Asistente de horas y facturación, y Lector de contratos.",
45+
},
46+
"legal-billing-assistant": {
47+
name: "Asistente de horas y facturación",
48+
role: "Convierte tu registro de trabajo en partes de horas claros y borradores de factura para un despacho o consultor, y muestra lo que aún no se ha facturado",
49+
summary:
50+
"Convierte tu registro de trabajo en partes de horas y borradores de factura, y muestra lo que falta por facturar",
51+
about:
52+
"Convierte tus notas y tu agenda en partes de horas con descripciones que un cliente entendería y que no revelan más de lo necesario. Muestra lo que aún no se ha facturado por cliente, señala partes que parecen erróneos sin cambiarlos y prepara el borrador de la factura con los partes que apruebes. Nunca redondea hacia arriba ni exagera el trabajo.",
53+
when: "Cuando facturas por horas y el tiempo se escapa antes de que factures.",
54+
pairs: "Asistente de cobros, para seguir los pagos, y Auxiliar contable.",
55+
},
56+
"contract-deadline-tracker": {
57+
name: "Control de plazos de contratos",
58+
role: "Sigue las fechas de tus contratos: renovaciones, preavisos, pagos y plazos, y te avisa con mucha antelación",
59+
summary:
60+
"Sigue las fechas de tus contratos, como renovaciones y preavisos, y te avisa con antelación",
61+
about:
62+
"Lee tus contratos y lista cada fecha y obligación con la cláusula de la que viene, calculando la fecha real y diciendo en palabras sencillas cómo se contó. Pone las trampas primero, como renovaciones automáticas con preaviso, y avisa pronto. Si una cláusula no está clara, lo dice en lugar de adivinar. Nunca envía un aviso ni termina un contrato.",
63+
when: "Cuando tienes varios contratos y temes perder una renovación o un aviso.",
64+
pairs:
65+
"Lector de contratos, para explicar una cláusula, y Redactor, para redactar un aviso que tú envías.",
66+
},
67+
"complaint-letter-drafter": {
68+
name: "Redactor de cartas de reclamación",
69+
role: "Redacta cartas claras, firmes y educadas para una queja o disputa con una empresa o un propietario, a partir de los hechos y los papeles que tienes",
70+
summary:
71+
"Redacta cartas de reclamación claras, firmes y educadas para una disputa con una empresa o propietario",
72+
about:
73+
"Ordena los hechos contigo, arma una línea de tiempo comprobada con tus papeles y redacta una carta corta, educada y firme: qué pasó, qué pides y un plazo razonable para responder. No amenaza ni exagera. Lista los anexos y los lugares donde probar después, como preguntas para tu país. La carta la envías tú.",
74+
when: "Cuando una empresa, un propietario o un vendedor no ha actuado bien contigo.",
75+
pairs: "Lector de contratos, para las cláusulas, y Corrector de textos, para revisar.",
76+
},
77+
};

‎app/src/i18n/pt-BR/catalog.ts‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ import { design } from "./catalogDesign";
55
import { engineering } from "./catalogEngineering";
66
import { engineeringMore } from "./catalogEngineeringMore";
77
import { finance } from "./catalogFinance";
8+
import { legal } from "./catalogLegal";
89
import { marketing } from "./catalogMarketing";
910
import { paidMedia } from "./catalogPaidMedia";
1011
import { people } from "./catalogPeople";
@@ -37,6 +38,7 @@ export const catalog: Messages["catalog"] = {
3738
finance: "Finanças",
3839
people: "Pessoas e RH",
3940
security: "Segurança",
41+
legal: "Jurídico",
4042
},
4143
none: "Nenhum bot combina com isso.",
4244
loading: "Carregando os bots…",
@@ -69,5 +71,6 @@ export const catalog: Messages["catalog"] = {
6971
...engineeringMore,
7072
...security,
7173
...sectors,
74+
...legal,
7275
},
7376
};

0 commit comments

Comments
 (0)