renobrief 0.1.0
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.
- package/LICENSE +21 -0
- package/README.md +43 -0
- package/cli.js +41 -0
- package/index.js +58 -0
- package/package.json +33 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 wujieli
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
ADDED
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
# renobrief
|
|
2
|
+
|
|
3
|
+
Estimate home renovation **budget ranges** by room, style, and scope — a small
|
|
4
|
+
companion tool for [RenoBrief AI](https://renobrief.com), which turns a room
|
|
5
|
+
photo into a redesigned image plus a contractor-ready one-page brief.
|
|
6
|
+
|
|
7
|
+
## Install
|
|
8
|
+
|
|
9
|
+
```bash
|
|
10
|
+
npm install renobrief
|
|
11
|
+
# or run directly:
|
|
12
|
+
npx renobrief kitchen --style quiet_luxury --scope gut --sqft 200
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## CLI
|
|
16
|
+
|
|
17
|
+
```bash
|
|
18
|
+
renobrief bathroom --style japandi --scope remodel
|
|
19
|
+
# bathroom · japandi · remodel
|
|
20
|
+
# Estimated budget: $5,750 – $28,750
|
|
21
|
+
# Get a full visual redesign + contractor-ready brief: https://renobrief.com
|
|
22
|
+
```
|
|
23
|
+
|
|
24
|
+
## API
|
|
25
|
+
|
|
26
|
+
```js
|
|
27
|
+
import { estimate } from "renobrief";
|
|
28
|
+
|
|
29
|
+
const [low, high] = estimate("kitchen", { style: "modern", scope: "remodel" });
|
|
30
|
+
console.log(low, high);
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
Rooms: `bathroom`, `kitchen`, `bedroom`, `living_room`, `exterior`
|
|
34
|
+
Styles: `minimalist`, `farmhouse`, `modern`, `japandi`, `quiet_luxury`
|
|
35
|
+
Scopes: `refresh`, `remodel`, `gut`
|
|
36
|
+
|
|
37
|
+
> Figures are planning ballparks (US market), not quotes. For an actual
|
|
38
|
+
> redesigned visualization, materials list, and a brief a contractor can quote
|
|
39
|
+
> against, use **[RenoBrief AI](https://renobrief.com)**.
|
|
40
|
+
|
|
41
|
+
## License
|
|
42
|
+
|
|
43
|
+
MIT
|
package/cli.js
ADDED
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
// CLI entry point: `renobrief`.
|
|
3
|
+
import { estimate, ROOMS, STYLES, SCOPES, HOMEPAGE } from "./index.js";
|
|
4
|
+
|
|
5
|
+
function parse(argv) {
|
|
6
|
+
const args = { style: "modern", scope: "remodel", sqft: undefined, room: undefined };
|
|
7
|
+
for (let i = 0; i < argv.length; i++) {
|
|
8
|
+
const a = argv[i];
|
|
9
|
+
if (a === "--style") args.style = argv[++i];
|
|
10
|
+
else if (a === "--scope") args.scope = argv[++i];
|
|
11
|
+
else if (a === "--sqft") args.sqft = Number(argv[++i]);
|
|
12
|
+
else if (a === "--version" || a === "-v") { console.log("renobrief 0.1.0"); process.exit(0); }
|
|
13
|
+
else if (a === "--help" || a === "-h") { usage(); process.exit(0); }
|
|
14
|
+
else if (!a.startsWith("-")) args.room = a;
|
|
15
|
+
}
|
|
16
|
+
return args;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
function usage() {
|
|
20
|
+
console.log(`Usage: renobrief <room> [--style S] [--scope S] [--sqft N]
|
|
21
|
+
|
|
22
|
+
rooms: ${Object.keys(ROOMS).join(", ")}
|
|
23
|
+
styles: ${Object.keys(STYLES).join(", ")}
|
|
24
|
+
scopes: ${Object.keys(SCOPES).join(", ")}
|
|
25
|
+
|
|
26
|
+
Full AI redesign + contractor-ready brief: ${HOMEPAGE}`);
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
const args = parse(process.argv.slice(2));
|
|
30
|
+
if (!args.room) { usage(); process.exit(1); }
|
|
31
|
+
|
|
32
|
+
try {
|
|
33
|
+
const [low, high] = estimate(args.room, { style: args.style, scope: args.scope, sqft: args.sqft });
|
|
34
|
+
const fmt = (n) => n.toLocaleString("en-US");
|
|
35
|
+
console.log(`${args.room} · ${args.style} · ${args.scope}`);
|
|
36
|
+
console.log(`Estimated budget: $${fmt(low)} – $${fmt(high)}`);
|
|
37
|
+
console.log(`Get a full visual redesign + contractor-ready brief: ${HOMEPAGE}`);
|
|
38
|
+
} catch (e) {
|
|
39
|
+
console.error(e.message);
|
|
40
|
+
process.exit(1);
|
|
41
|
+
}
|
package/index.js
ADDED
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
// renobrief — home renovation budget range estimator.
|
|
2
|
+
// Companion SDK for RenoBrief AI (https://renobrief.com), which turns a room
|
|
3
|
+
// photo into a redesigned image plus a contractor-ready renovation brief.
|
|
4
|
+
|
|
5
|
+
export const HOMEPAGE = "https://renobrief.com";
|
|
6
|
+
|
|
7
|
+
// Baseline low/high cost per room (USD), assuming a standard-size room.
|
|
8
|
+
export const ROOMS = {
|
|
9
|
+
bathroom: [5_000, 25_000],
|
|
10
|
+
kitchen: [12_000, 50_000],
|
|
11
|
+
bedroom: [2_000, 15_000],
|
|
12
|
+
living_room: [3_000, 20_000],
|
|
13
|
+
exterior: [5_000, 40_000],
|
|
14
|
+
};
|
|
15
|
+
|
|
16
|
+
// Finish-level multiplier. Quiet luxury runs the highest.
|
|
17
|
+
export const STYLES = {
|
|
18
|
+
minimalist: 0.9,
|
|
19
|
+
farmhouse: 1.0,
|
|
20
|
+
modern: 1.1,
|
|
21
|
+
japandi: 1.15,
|
|
22
|
+
quiet_luxury: 1.4,
|
|
23
|
+
};
|
|
24
|
+
|
|
25
|
+
// How deep the work goes.
|
|
26
|
+
export const SCOPES = {
|
|
27
|
+
refresh: 0.4, // paint, fixtures, styling
|
|
28
|
+
remodel: 1.0, // standard renovation
|
|
29
|
+
gut: 1.6, // down to the studs
|
|
30
|
+
};
|
|
31
|
+
|
|
32
|
+
/**
|
|
33
|
+
* Return a [low, high] budget range in USD.
|
|
34
|
+
* @param {string} room one of ROOMS
|
|
35
|
+
* @param {object} [opts]
|
|
36
|
+
* @param {string} [opts.style="modern"]
|
|
37
|
+
* @param {string} [opts.scope="remodel"]
|
|
38
|
+
* @param {number} [opts.sqft] optional room size, scaled vs ~120 sqft baseline
|
|
39
|
+
*/
|
|
40
|
+
export function estimate(room, { style = "modern", scope = "remodel", sqft } = {}) {
|
|
41
|
+
if (!(room in ROOMS)) {
|
|
42
|
+
throw new Error(`unknown room '${room}'; choose from ${Object.keys(ROOMS).join(", ")}`);
|
|
43
|
+
}
|
|
44
|
+
if (!(style in STYLES)) {
|
|
45
|
+
throw new Error(`unknown style '${style}'; choose from ${Object.keys(STYLES).join(", ")}`);
|
|
46
|
+
}
|
|
47
|
+
if (!(scope in SCOPES)) {
|
|
48
|
+
throw new Error(`unknown scope '${scope}'; choose from ${Object.keys(SCOPES).join(", ")}`);
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
const [low, high] = ROOMS[room];
|
|
52
|
+
let factor = STYLES[style] * SCOPES[scope];
|
|
53
|
+
if (sqft) factor *= Math.max(0.5, Number(sqft) / 120);
|
|
54
|
+
|
|
55
|
+
return [Math.round(low * factor), Math.round(high * factor)];
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
export default estimate;
|
package/package.json
ADDED
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "renobrief",
|
|
3
|
+
"version": "0.1.0",
|
|
4
|
+
"description": "Estimate home renovation budget ranges by room, style, and scope. Companion CLI for RenoBrief AI (https://renobrief.com).",
|
|
5
|
+
"keywords": [
|
|
6
|
+
"renovation",
|
|
7
|
+
"home-improvement",
|
|
8
|
+
"budget",
|
|
9
|
+
"remodel",
|
|
10
|
+
"interior-design",
|
|
11
|
+
"estimator"
|
|
12
|
+
],
|
|
13
|
+
"homepage": "https://renobrief.com",
|
|
14
|
+
"repository": {
|
|
15
|
+
"type": "git",
|
|
16
|
+
"url": "git+https://github.com/wujieli0207/renobrief.git"
|
|
17
|
+
},
|
|
18
|
+
"license": "MIT",
|
|
19
|
+
"author": "wujieli",
|
|
20
|
+
"type": "module",
|
|
21
|
+
"main": "index.js",
|
|
22
|
+
"bin": {
|
|
23
|
+
"renobrief": "cli.js"
|
|
24
|
+
},
|
|
25
|
+
"files": [
|
|
26
|
+
"index.js",
|
|
27
|
+
"cli.js",
|
|
28
|
+
"README.md"
|
|
29
|
+
],
|
|
30
|
+
"engines": {
|
|
31
|
+
"node": ">=16"
|
|
32
|
+
}
|
|
33
|
+
}
|