dwelldelta-mcp 0.13.0 → 0.15.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 +7 -2
- package/README.md +48 -10
- package/contribute-tool.mjs +1 -1
- package/cover-tool.mjs +360 -0
- package/output-schemas.mjs +8 -1
- package/package.json +3 -2
- package/place-tool.mjs +153 -27
- package/register-tools.mjs +13 -5
- package/server.mjs +2 -2
- package/tools.mjs +16 -4
- package/vendor/act-rents-interim.json +362 -0
- package/vendor/contribute.mjs +126 -15
- package/vendor/nt-rents-interim.json +479 -0
- package/vendor/nz-rents.json +1033 -0
- package/vendor/tas-rents-interim.json +1372 -0
package/LICENSE
CHANGED
|
@@ -21,7 +21,8 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
|
21
21
|
SOFTWARE.
|
|
22
22
|
|
|
23
23
|
The data files in vendor/ (rents-index.json, indicators.json, nsw-suburbs.json, vic-rents.json,
|
|
24
|
-
nsw-rents.json, qld-rents.json, wa-rents.json, sa-rents.json, nsw-sales.json
|
|
24
|
+
nsw-rents.json, qld-rents.json, wa-rents.json, sa-rents.json, nsw-sales.json, nz-rents.json,
|
|
25
|
+
act-rents-interim.json, nt-rents-interim.json, tas-rents-interim.json) are
|
|
25
26
|
not covered by this licence. Each figure keeps its source's own licence and
|
|
26
27
|
attribution, which the data files and every answer state (for example, ABS data:
|
|
27
28
|
CC BY 4.0, "Based on Australian Bureau of Statistics data"; the NSW suburb list:
|
|
@@ -34,4 +35,8 @@ SA rents: South Australian Housing Trust, Government of South Australia,
|
|
|
34
35
|
Private Rent Report, whose own page states no licence - the national
|
|
35
36
|
catalogues list CC BY 4.0 and CC BY 3.0 AU;
|
|
36
37
|
NSW sale prices: CC BY 4.0, State of New South Wales (Department of
|
|
37
|
-
Communities and Justice)
|
|
38
|
+
Communities and Justice); New Zealand rents: CC BY 3.0 NZ, the Ministry of
|
|
39
|
+
Business, Innovation and Employment, Tenancy Services rental bond data; ACT,
|
|
40
|
+
Northern Territory and Tasmania interim rent cover: CC BY 4.0, Commonwealth of
|
|
41
|
+
Australia (Australian Bureau of Statistics), "Based on Australian Bureau of
|
|
42
|
+
Statistics data").
|
package/README.md
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
# dwelldelta-mcp - is an Australian rent fair?
|
|
2
2
|
|
|
3
3
|
An MCP server that lets an AI assistant check a weekly rent against the ABS rents index, look up median rents
|
|
4
|
-
by area in five states and
|
|
4
|
+
by area in five states and New Zealand (with interim ABS cover for the ACT, the Northern Territory and Tasmania) and
|
|
5
|
+
NSW median sale prices, and quote sourced Australian property and lending indicators. From
|
|
5
6
|
[DwellDelta](https://dwelldelta.com.au/), a service of Xcelerent Pty Ltd, built on public data.
|
|
6
7
|
|
|
7
8
|
Seven read-only tools, and one that adds the user's own rent when they ask:
|
|
@@ -9,7 +10,7 @@ Seven read-only tools, and one that adds the user's own rent when they ask:
|
|
|
9
10
|
| Tool | What it answers |
|
|
10
11
|
|---|---|
|
|
11
12
|
| `rent_check` | a weekly rent, and any proposed new rent, against the ABS rents index for the capital city since the lease began (the same arithmetic as the rent check at tools.dwelldelta.com.au); or, given a `place` instead of a lease start, against that place's median of new bonds or leases, and its quartiles where published (from 0.12.0) |
|
|
12
|
-
| `property_rents` | the rents of a place asked with no state - a suburb, locality or postcode - answered from the state that holds it (NSW, Victoria, Queensland, WA or SA); an NSW suburb is answered for its postcode, and a name held in more than one state is listed, not chosen (from 0.12.0) |
|
|
13
|
+
| `property_rents` | the rents of a place asked with no state - a suburb, locality or postcode - answered from the state that holds it (NSW, Victoria, Queensland, WA or SA); an NSW suburb is answered for its postcode, and a name held in more than one state is listed, not chosen (from 0.12.0). From 0.14.0 also a New Zealand council or region (MBIE's bonds for one month, in NZ$, provisional) and an ACT, NT or Tasmanian postcode (interim ABS cover: the rent paid at the 2021 Census, the capital's rents index, sale prices - not new-bond medians) |
|
|
13
14
|
| `market_indicators` | the latest RBA cash rate, unemployment, wage growth, rents for all eight capitals, NSW lending, lending standards and arrears, approvals and completions - each with period, source, licence and limits; filter by `geography` |
|
|
14
15
|
| `vic_rents` | Victorian rents by suburb group from Homes Victoria's Rental Report: the median weekly rent of new leases, the lease count and the change on a year before, for 146 suburb groups and 13 regions; filter by `suburb_group` or `region` (from 0.5.0) |
|
|
15
16
|
| `area_rents` | median weekly rent of new bonds, all dwellings together, with the bond count and the change on a year before, for one state per call: NSW by postcode or council (NSW Department of Communities and Justice), Queensland by suburb or council (Residential Tenancies Authority), WA by locality (calculated by DwellDelta from the Government of Western Australia's bond records), SA by suburb (SA Housing Trust, Private Rent Report; its publisher's page states no licence, and the national catalogues list CC BY); each file states CC BY 4.0 (from 0.6.0; SA from 0.11.0) |
|
|
@@ -19,9 +20,9 @@ Seven read-only tools, and one that adds the user's own rent when they ask:
|
|
|
19
20
|
|
|
20
21
|
It runs on your own machine over stdio. It records nothing and sends nothing about you unless you choose to add
|
|
21
22
|
your rent. At start it fetches DwellDelta's published files from tools.dwelldelta.com.au - the week's indicators,
|
|
22
|
-
the rents and sale prices it answers from, and (from 0.9.0) the ABS rents index behind `rent_check`,
|
|
23
|
-
files in all, the same for everyone; nothing about you or your questions is sent - and otherwise uses the
|
|
24
|
-
ships with. Set `DWELLDELTA_OFFLINE=1` and none of those
|
|
23
|
+
the rents and sale prices it answers from, and (from 0.9.0) the ABS rents index behind `rent_check`, fourteen public
|
|
24
|
+
files in all from 0.14.0, the same for everyone; nothing about you or your questions is sent - and otherwise uses the
|
|
25
|
+
copies it ships with (all but the two rents by dwelling type files). Set `DWELLDELTA_OFFLINE=1` and none of those files is fetched; adding a rent with `contribute_rent` still sends it, as you asked. Nothing it says is a
|
|
25
26
|
forecast, a valuation or advice.
|
|
26
27
|
|
|
27
28
|
## Adding a rent (from 0.5.0)
|
|
@@ -35,6 +36,13 @@ property you own - never an address, name or email. You get a deletion code; ema
|
|
|
35
36
|
and the record is deleted. Only your own rent may be added: an assistant must not add a figure it read on a
|
|
36
37
|
website or a listing.
|
|
37
38
|
|
|
39
|
+
From 0.15.0 it sends terms version 2026-11-03, whose consent, Contributor Terms and Privacy Notice name the lease
|
|
40
|
+
kind (whether it is a new lease or a renewal), which every contribution has recorded. 0.10.1 to 0.14.0 send
|
|
41
|
+
2026-10-27, which the endpoint accepts for now; once that stops, their contributions are refused (HTTP 409) - update
|
|
42
|
+
to 0.15.0 or later. From 0.15.0 a refusal the endpoint is known to give also says what to do, in the package's own
|
|
43
|
+
words ("Not added: the contribution was not saved (HTTP 409): the terms have changed: update dwelldelta-mcp (npx -y
|
|
44
|
+
dwelldelta-mcp@latest)."); any other reason gives the status alone.
|
|
45
|
+
|
|
38
46
|
## NSW sale prices (from 0.7.0)
|
|
39
47
|
|
|
40
48
|
`nsw_sale_prices` gives DCJ's medians for the dwellings sold in a quarter - not asking prices, not valuations,
|
|
@@ -57,14 +65,16 @@ Claude Desktop - add to `claude_desktop_config.json`:
|
|
|
57
65
|
"mcpServers": {
|
|
58
66
|
"dwelldelta": {
|
|
59
67
|
"command": "npx",
|
|
60
|
-
"args": ["-y", "dwelldelta-mcp"]
|
|
68
|
+
"args": ["-y", "dwelldelta-mcp@latest"]
|
|
61
69
|
}
|
|
62
70
|
}
|
|
63
71
|
}
|
|
64
72
|
```
|
|
65
73
|
|
|
66
|
-
Claude Code: `claude mcp add dwelldelta -- npx -y dwelldelta-mcp`. Any other MCP client: run
|
|
67
|
-
as a stdio server. Node 18 or later.
|
|
74
|
+
Claude Code: `claude mcp add dwelldelta -- npx -y dwelldelta-mcp@latest`. Any other MCP client: run
|
|
75
|
+
`npx -y dwelldelta-mcp@latest` as a stdio server. Node 18 or later. On npm 9 and later npx already checks for a
|
|
76
|
+
newer release; `@latest` matters on npm 8, and where dwelldelta-mcp is installed globally or in a project, which npx
|
|
77
|
+
would otherwise run as installed.
|
|
68
78
|
|
|
69
79
|
Then ask: "Is a rise from $700 to $770 a week in Sydney since July 2025 in line with rents?", "What is the
|
|
70
80
|
median rent of new leases in postcode 2148?" or "What is NSW unemployment doing?"
|
|
@@ -110,6 +120,28 @@ by-type question fails with the next step, and every other answer is unaffected.
|
|
|
110
120
|
|
|
111
121
|
It is listed in the MCP registry as `au.com.dwelldelta/dwelldelta`.
|
|
112
122
|
|
|
123
|
+
## New Zealand, and the ACT, the Northern Territory and Tasmania (from 0.14.0)
|
|
124
|
+
|
|
125
|
+
`property_rents` answers these too, each in fields of its own - never `area_rents`, whose fields mean a median of new
|
|
126
|
+
bonds lodged in an Australian quarter, in Australian dollars. Nothing is compared across states or countries.
|
|
127
|
+
|
|
128
|
+
- **New Zealand**, by council (territorial authority) or region, as MBIE names them ("Wellington City", "Auckland",
|
|
129
|
+
"Canterbury Region"; "Wellington, NZ" lists the city and the region): MBIE Tenancy Services' median weekly rent of
|
|
130
|
+
the bonds for private tenancies that began in the latest month, with its geometric mean, quartiles and bond count,
|
|
131
|
+
CC BY 3.0 NZ. Every amount is in New Zealand dollars, written NZ$, in fields ending `_nzd`; MBIE calls the data
|
|
132
|
+
provisional, so no change on a year is given. A figure on fewer than 30 bonds is a small sample; MBIE gives none
|
|
133
|
+
below 5. The answer carries `country: "NZ"`, `currency: "NZD"`, `provisional: true`, `nz_place`, and the place's
|
|
134
|
+
page at tools.dwelldelta.com.au/area/nz/.
|
|
135
|
+
- **The ACT, the Northern Territory and Tasmania**, by postcode, or the state or its capital alone: interim ABS cover,
|
|
136
|
+
CC BY 4.0 - the median weekly rent paid in the postal area on Census night, 10 August 2021 (leases new and old,
|
|
137
|
+
every landlord), the capital's CPI rents index and ABS median sale prices, each with its period. None is a median
|
|
138
|
+
of new bonds or today's rent. A postal area under half privately rented carries "Mostly not private rentals: do not
|
|
139
|
+
quote as a market rent."; a small Census sample is marked; where fewer than 10 households stated their rent there is
|
|
140
|
+
no dollar median, only "Too few households for a median (N)". The answer carries `interim: true`, `census_period`,
|
|
141
|
+
`postal_area`, `cpi_rents` and `dwelling_prices`, and the state's page (/area/act/, /area/nt/, /area/tas/).
|
|
142
|
+
- `rent_check` places no rent against either: not an Australian-dollar rent against NZ$ figures, and not against a
|
|
143
|
+
2021 Census median.
|
|
144
|
+
|
|
113
145
|
## What an agent gets back
|
|
114
146
|
|
|
115
147
|
Every call returns text to quote and a structured result: the figures, plus `sources` (each with its licence and
|
|
@@ -229,8 +261,14 @@ published data file. The structured result says the same, in new fields; every f
|
|
|
229
261
|
`period_due_by` is the day by which the release after this period was due, and `period_overdue` is true once it
|
|
230
262
|
has passed with no newer file. A quarterly rents file is overdue once its quarter ended more than seven months
|
|
231
263
|
ago (the next quarter, plus the publisher's lag), NSW sale prices after ten (DCJ's sales run a quarter behind its
|
|
232
|
-
rents), and the ABS monthly rents index
|
|
233
|
-
|
|
264
|
+
rents), and the ABS monthly rents index (`rent_check`) three months after its latest month (two to 0.14.0, which
|
|
265
|
+
flagged every January overdue: the ABS releases November's figures in early January). From 0.15.0, New Zealand's MBIE
|
|
266
|
+
month (`property_rents` with NZ) is overdue three months after it, and the ACT, NT and Tasmania interim cover
|
|
267
|
+
three months after its rents index month (to 0.14.0 neither carried a due date); the interim cover's 2021 Census figures are fixed until the next
|
|
268
|
+
Census, and are not flagged, and its ABS sale-price quarter is not checked for staleness (the flag follows the
|
|
269
|
+
rents index month alone). An overdue answer opens with a `STALE:` line giving the reason (through `property_rents`, the
|
|
270
|
+
line after its `Place:` line), and its `Cite:` line ends `; STALE.` - as an old snapshot's does (the interim cover
|
|
271
|
+
has no `Cite:` line: it carries the `STALE:` line alone).
|
|
234
272
|
- `figures` (`area_rents`, with or without `dwelling_type` and `bedrooms`, `vic_rents`, `nsw_sale_prices`): one
|
|
235
273
|
entry per figure of the answer, with `n`, `n_band` (where the publisher withholds the exact count), `unit`,
|
|
236
274
|
`small_sample` and `refusal`. `refusals` lists the refused ones, `all_refused` says whether anything may be
|
package/contribute-tool.mjs
CHANGED
|
@@ -129,7 +129,7 @@ export function makeContributeTool({
|
|
|
129
129
|
const code = deletionCode(randomBytes(12));
|
|
130
130
|
const body = { ...payload(record, await hashCode(code), t.toISOString().slice(0, 10)), whose: args.whose };
|
|
131
131
|
try {
|
|
132
|
-
await submitContribution(body, { endpoint, fetchImpl });
|
|
132
|
+
await submitContribution(body, { endpoint, fetchImpl, door: "tool" });
|
|
133
133
|
} catch (err) {
|
|
134
134
|
throw new ToolError(`Not added: ${err.message}.`, "Tell the user it was not added. Do not retry automatically.");
|
|
135
135
|
}
|
package/cover-tool.mjs
ADDED
|
@@ -0,0 +1,360 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* New Zealand, and the ACT, the Northern Territory and Tasmania (0.14.0; owner, 2026-11-03: "make the MCP tools serve
|
|
3
|
+
* NZ or ACT/NT/TAS as well"). Answered through property_rents (place-tool.mjs), never area_rents: area_rents' state
|
|
4
|
+
* enum, its median_weekly_rent_aud, new_bonds and quarter fields and its words all mean a median of new bonds lodged in
|
|
5
|
+
* an Australian quarter, in Australian dollars, and a released field keeps its meaning. These answers carry fields of
|
|
6
|
+
* their own instead.
|
|
7
|
+
*
|
|
8
|
+
* - New Zealand: market/nz-rents.json, MBIE Tenancy Services' bonds for the tenancies that began in one month, by
|
|
9
|
+
* territorial authority (council) and region, CC BY 3.0 NZ. Every amount is New Zealand dollars - fields ending
|
|
10
|
+
* _nzd, written NZ$ - never AUD; MBIE calls the data provisional, so no change on a year is given (the file nulls
|
|
11
|
+
* it); and nothing is set beside an Australian figure.
|
|
12
|
+
* - The ACT, the NT and Tasmania: market/{act,nt,tas}-rents-interim.json, interim ABS cover, CC BY 4.0: the median
|
|
13
|
+
* weekly rent PAID in each postal area on Census night 2021, the capital's CPI rents index and ABS median sale
|
|
14
|
+
* prices. None of it is a median of new bonds, and no answer calls it one; every figure carries its period; the
|
|
15
|
+
* file's flags are said in its words (tools/render-area-pages.mjs INTERIM_FLAGS, held to these by
|
|
16
|
+
* tests/mcp-pages.test.mjs); a postal area where fewer than 10 households stated their rent gets no dollar
|
|
17
|
+
* median, only "Too few households for a median (N)", as the site's page.
|
|
18
|
+
*
|
|
19
|
+
* Loaded like the state rents feeds: DWELLDELTA_STATE_RENTS_DIR where it holds the file, else the owner's live store,
|
|
20
|
+
* else the published file (fetched once at start; nothing about the user or the question is sent) where well formed
|
|
21
|
+
* and not older than the bundled copy, else the copy bundled at pack time. DWELLDELTA_OFFLINE=1 never fetches.
|
|
22
|
+
*/
|
|
23
|
+
import { existsSync } from "node:fs";
|
|
24
|
+
import { fileURLToPath } from "node:url";
|
|
25
|
+
import { dirname, join } from "node:path";
|
|
26
|
+
import { envelope, ToolError, FOOTER, FETCH_TIMEOUT_MS, feedSource, citeLine, isRecord, passes, readChecked, quiet,
|
|
27
|
+
warnPublished, fromCopy, CADENCE, staleNote, flagged } from "./tools.mjs";
|
|
28
|
+
import { SITE, slug } from "./pages.mjs";
|
|
29
|
+
|
|
30
|
+
const HERE = dirname(fileURLToPath(import.meta.url));
|
|
31
|
+
const LIVE_DIR = join(HERE, "..", "..", "dwelldelta-data", "market");
|
|
32
|
+
const BUNDLED_DIR = join(HERE, "vendor");
|
|
33
|
+
const PUBLISHED_BASE = "https://tools.dwelldelta.com.au/market/";
|
|
34
|
+
export const NZ_FILE = "nz-rents.json";
|
|
35
|
+
export const INTERIM = {
|
|
36
|
+
ACT: { file: "act-rents-interim.json", name: "the Australian Capital Territory", page: "act" },
|
|
37
|
+
NT: { file: "nt-rents-interim.json", name: "the Northern Territory", page: "nt" },
|
|
38
|
+
TAS: { file: "tas-rents-interim.json", name: "Tasmania", page: "tas" },
|
|
39
|
+
};
|
|
40
|
+
/** The site's own rules (tools/render-area-pages.mjs NZ_MIN_BONDS, NZ_SMALL, INTERIM_FEW, INTERIM_FLAGS). */
|
|
41
|
+
export const NZ_MIN_BONDS = 5;
|
|
42
|
+
export const NZ_SMALL = 30;
|
|
43
|
+
export const INTERIM_FEW = 10;
|
|
44
|
+
export const INTERIM_FLAGS = { mostly: "Mostly not private rentals: do not quote as a market rent.",
|
|
45
|
+
small: "Small Census sample (under 30 households): do not quote as typical of the area." };
|
|
46
|
+
/** Keys a state rents feed gives a meaning of its own (render-area-pages.mjs BOND_FIELDS): no interim answer has one. */
|
|
47
|
+
export const BOND_FIELDS = ["median_weekly_rent_aud", "first_quartile_aud", "third_quartile_aud", "new_bonds", "new_bonds_band",
|
|
48
|
+
"new_bonds_range", "change_pct", "year_ago_median_aud", "small_sample", "withheld", "quarter", "compared_with",
|
|
49
|
+
"state_total", "areas", "councils", "regions", "area_kind"];
|
|
50
|
+
|
|
51
|
+
const ym = (v) => /^\d{4}-\d{2}$/.test(v ?? "");
|
|
52
|
+
const hasAud = (f) => /"[a-z_]*_aud"\s*:/.test(JSON.stringify(f));
|
|
53
|
+
/** A New Zealand file this code may answer from: NZD, provisional with no change given, and no field in AUD. */
|
|
54
|
+
export const nzWellFormed = (f) => isRecord(f) && f.country === "NZ" && f.currency === "NZD" && ym(f.month)
|
|
55
|
+
&& typeof f.month_words === "string" && Array.isArray(f.areas) && f.areas.length > 0 && Array.isArray(f.regions)
|
|
56
|
+
&& Array.isArray(f.limits) && f.licence === "CC BY 3.0 NZ" && Boolean(f.attribution) && f.provisional === true
|
|
57
|
+
&& f.compared_with == null && !hasAud(f)
|
|
58
|
+
&& [...f.areas, ...f.regions].every((r) => !isRecord(r) || (r.change_pct == null && r.year_ago_median_nzd == null));
|
|
59
|
+
/** An interim file this code may answer from: its own state, interim, and no field a rents feed gives a bond meaning. */
|
|
60
|
+
const bondKeys = (n) => (Array.isArray(n) ? n.flatMap(bondKeys) : isRecord(n)
|
|
61
|
+
? Object.entries(n).flatMap(([k, v]) => [...(BOND_FIELDS.includes(k) ? [k] : []), ...bondKeys(v)]) : []);
|
|
62
|
+
export const interimWellFormed = (f, state) => isRecord(f) && f.state === state && f.interim === true
|
|
63
|
+
&& f.measure === "interim_rent_cover" && Array.isArray(f.limits) && Boolean(f.attribution) && f.licence === "CC BY 4.0"
|
|
64
|
+
&& isRecord(f.census_2021) && /^\d{4}-\d{2}-\d{2}$/.test(f.census_2021.census_date ?? "")
|
|
65
|
+
&& Array.isArray(f.census_2021.postcodes) && f.census_2021.postcodes.length > 0
|
|
66
|
+
&& isRecord(f.cpi_rents) && ym(f.cpi_rents.latest_month) && isRecord(f.dwelling_prices)
|
|
67
|
+
&& Array.isArray(f.dwelling_prices.places) && bondKeys(f).length === 0;
|
|
68
|
+
/** Which of two copies is newer: the month (NZ) or the day it was built (interim). */
|
|
69
|
+
const age = (f) => String(f?.month ?? f?.built ?? "");
|
|
70
|
+
|
|
71
|
+
async function loadCover(file, check, what, { env = process.env, fetchImpl = globalThis.fetch, liveDir = LIVE_DIR,
|
|
72
|
+
bundledDir = BUNDLED_DIR, warn = quiet } = {}) {
|
|
73
|
+
const read = (path, variable) => readChecked(path, check, what, variable, warn);
|
|
74
|
+
// A folder named by the variable that lacks this file (one made before 0.14.0) falls through to the others.
|
|
75
|
+
if (env.DWELLDELTA_STATE_RENTS_DIR && existsSync(join(env.DWELLDELTA_STATE_RENTS_DIR, file))) {
|
|
76
|
+
return fromCopy(await read(join(env.DWELLDELTA_STATE_RENTS_DIR, file), "DWELLDELTA_STATE_RENTS_DIR"), "feed", "env");
|
|
77
|
+
}
|
|
78
|
+
if (existsSync(join(liveDir, file))) return fromCopy(await read(join(liveDir, file)), "feed", "live");
|
|
79
|
+
const shipped = (await read(join(bundledDir, file))).copy;
|
|
80
|
+
if (env.DWELLDELTA_OFFLINE !== "1" && typeof fetchImpl === "function") {
|
|
81
|
+
try {
|
|
82
|
+
const res = await fetchImpl(PUBLISHED_BASE + file, { signal: AbortSignal.timeout(FETCH_TIMEOUT_MS) });
|
|
83
|
+
const got = res.ok ? await res.json() : null;
|
|
84
|
+
if (got != null && !passes(check, got)) warnPublished(warn, what, PUBLISHED_BASE + file, shipped);
|
|
85
|
+
if (passes(check, got) && (!shipped || age(got) >= age(shipped))) return { feed: got, origin: "published" };
|
|
86
|
+
} catch {
|
|
87
|
+
// Offline, blocked or slow: the bundled copy answers, and its period says how current it is.
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
return { feed: shipped, origin: shipped ? "bundled" : null };
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
/**
|
|
94
|
+
* { nz, interim: { ACT, NT, TAS }, refused }: each a feed with its origin, or null; refused names, by key (NZ, ACT, NT,
|
|
95
|
+
* TAS), a copy that failed its check, so a tool can say so rather than that there is none. The four are asked for
|
|
96
|
+
* together (Promise.all), so the stdio server's start waits for one fetch timeout at most, not four (the cold review).
|
|
97
|
+
*/
|
|
98
|
+
export async function loadCoverFeeds(opts = {}) {
|
|
99
|
+
const withOrigin = (l) => (l.feed ? { ...l.feed, origin: l.origin } : null);
|
|
100
|
+
const states = Object.keys(INTERIM);
|
|
101
|
+
const [nz, ...each] = await Promise.all([
|
|
102
|
+
loadCover(NZ_FILE, nzWellFormed, "the New Zealand rents feed", opts),
|
|
103
|
+
...states.map((state) => loadCover(INTERIM[state].file, (f) => interimWellFormed(f, state),
|
|
104
|
+
`the ${state} interim rent cover file`, opts)),
|
|
105
|
+
]);
|
|
106
|
+
const refused = Object.fromEntries([["NZ", nz], ...states.map((s, i) => [s, each[i]])]
|
|
107
|
+
.filter(([, l]) => l.refused).map(([k, l]) => [k, l.refused]));
|
|
108
|
+
return { nz: withOrigin(nz), interim: Object.fromEntries(states.map((s, i) => [s, withOrigin(each[i])])), refused };
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
// --- New Zealand -----------------------------------------------------------------------------------------------------
|
|
112
|
+
|
|
113
|
+
const fold = (s) => String(s ?? "").normalize("NFKD").replace(/[̀-ͯ]/g, "").replace(/[’']/g, "'")
|
|
114
|
+
.trim().replace(/\s+/g, " ").toLowerCase();
|
|
115
|
+
const shortName = (n) => n.replace(/ (city|district|region)$/i, "");
|
|
116
|
+
|
|
117
|
+
/** Every New Zealand place row: { kind: "council" | "region", name, row }. */
|
|
118
|
+
export function nzPlaces(feed) {
|
|
119
|
+
if (!feed) return [];
|
|
120
|
+
return [...feed.areas.filter(isRecord).map((r) => ({ kind: "council", name: String(r.area), row: r })),
|
|
121
|
+
...feed.regions.filter(isRecord).map((r) => ({ kind: "region", name: String(r.region), row: r }))];
|
|
122
|
+
}
|
|
123
|
+
/**
|
|
124
|
+
* The New Zealand places a name is: by its full name as MBIE gives it ("Wellington City", "Auckland"), always; by its
|
|
125
|
+
* name without "City", "District" or "Region" ("Wellington") only where the asker said New Zealand, and then only if
|
|
126
|
+
* no full name matched - "Wellington" alone is the NSW postcode it has always been.
|
|
127
|
+
*/
|
|
128
|
+
export function nzMatches(name, feed, saidNz = false) {
|
|
129
|
+
const want = fold(name);
|
|
130
|
+
if (!want) return [];
|
|
131
|
+
const places = nzPlaces(feed);
|
|
132
|
+
const exact = places.filter((p) => fold(p.name) === want);
|
|
133
|
+
if (exact.length || !saidNz) return exact;
|
|
134
|
+
return places.filter((p) => fold(shortName(p.name)) === want);
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
/** The site's addresses for New Zealand (render-area-pages.mjs nzPlaces): given across every row, by name alone. */
|
|
138
|
+
const nzMemo = new WeakMap();
|
|
139
|
+
function nzAddresses(feed) {
|
|
140
|
+
if (nzMemo.has(feed)) return nzMemo.get(feed);
|
|
141
|
+
const rows = nzPlaces(feed).map((p) => ({ ...p, slug: slug(p.name) }));
|
|
142
|
+
const seen = new Set(), out = new Map();
|
|
143
|
+
for (const p of [...rows].sort((a, b) => (a.slug < b.slug ? -1 : a.slug > b.slug ? 1 : a.name < b.name ? -1 : a.name > b.name ? 1 : 0))) {
|
|
144
|
+
if (!p.slug) continue;
|
|
145
|
+
let s = p.slug;
|
|
146
|
+
for (let n = 2; seen.has(s); n++) s = `${p.slug}-${n}`;
|
|
147
|
+
seen.add(s);
|
|
148
|
+
out.set(`${p.kind}:${p.name}`, s);
|
|
149
|
+
}
|
|
150
|
+
nzMemo.set(feed, out);
|
|
151
|
+
return out;
|
|
152
|
+
}
|
|
153
|
+
const NZ_FIGURES = ["median_weekly_rent_nzd", "geometric_mean_weekly_rent_nzd", "lower_quartile_weekly_rent_nzd",
|
|
154
|
+
"upper_quartile_weekly_rent_nzd", "new_bonds", "active_bonds"];
|
|
155
|
+
export const nzShown = (r) => isRecord(r) && Number.isFinite(r.median_weekly_rent_nzd) && Number.isFinite(r.new_bonds)
|
|
156
|
+
&& r.new_bonds >= NZ_MIN_BONDS;
|
|
157
|
+
export const nzSmall = (r) => r.small_sample === true || !(r.new_bonds >= NZ_SMALL);
|
|
158
|
+
/**
|
|
159
|
+
* A place's page, or null where the site builds none: a place with a figure it may show. A region whose every figure is
|
|
160
|
+
* a council's, and whose name the council's begins with (Auckland), has the council's page, which stands for both.
|
|
161
|
+
*/
|
|
162
|
+
export function nzPage(feed, place) {
|
|
163
|
+
if (!nzShown(place.row)) return null;
|
|
164
|
+
if (place.kind === "region") {
|
|
165
|
+
const base = place.name.replace(/ Region$/, "");
|
|
166
|
+
const twin = nzPlaces(feed).filter((p) => p.kind === "council" && nzShown(p.row))
|
|
167
|
+
.sort((a, b) => a.name.localeCompare(b.name, "en-NZ"))
|
|
168
|
+
.find((c) => c.name.startsWith(base) && NZ_FIGURES.every((k) => c.row[k] === place.row[k]));
|
|
169
|
+
if (twin) return nzPage(feed, twin);
|
|
170
|
+
}
|
|
171
|
+
const s = nzAddresses(feed).get(`${place.kind}:${place.name}`);
|
|
172
|
+
return s ? `${SITE}/area/nz/${s}/` : null;
|
|
173
|
+
}
|
|
174
|
+
|
|
175
|
+
/** New Zealand dollars, always marked: NZ$650; NZ$472.50. Never a bare $. */
|
|
176
|
+
export const nzd = (v) => {
|
|
177
|
+
const n = Number(v);
|
|
178
|
+
return `NZ$${n.toLocaleString("en-NZ", Number.isInteger(n) ? {} : { minimumFractionDigits: 2, maximumFractionDigits: 2 })}`;
|
|
179
|
+
};
|
|
180
|
+
/** The file's own words, with any amount marked as New Zealand dollars. */
|
|
181
|
+
const nzWords = (s) => String(s).replace(/(^|[^A-Za-z])\$(?=\d)/g, (m, before) => `${before}NZ$`);
|
|
182
|
+
const MBIE_PAGE = (f) => f.source_notice ?? null;
|
|
183
|
+
|
|
184
|
+
/** One New Zealand place's answer: MBIE's month, in NZ$, provisional, with no change on a year. */
|
|
185
|
+
export function nzResult(place, feed, now = new Date()) {
|
|
186
|
+
const r = place.row;
|
|
187
|
+
const kind = place.kind === "region" ? "region" : "territorial authority";
|
|
188
|
+
const src = feedSource(feed, PUBLISHED_BASE + NZ_FILE, feed.month, { noticeIsData: true });
|
|
189
|
+
const env = envelope({ sources: [src], dataAsOf: feed.month, origin: feed.origin ?? null, cadence: CADENCE.nz_monthly },
|
|
190
|
+
now);
|
|
191
|
+
const shown = nzShown(r);
|
|
192
|
+
const small = shown && nzSmall(r);
|
|
193
|
+
const url = nzPage(feed, place);
|
|
194
|
+
const cite = shown ? `Median weekly rent of new bonds, ${place.name} (${kind}), New Zealand, ${feed.month_words} ` +
|
|
195
|
+
`(provisional). Source: ${feed.rights_holder}, ${feed.licence}. Via DwellDelta: ${url ?? `${SITE}/area/nz/`}` : null;
|
|
196
|
+
const money = (k) => (Number.isFinite(r[k]) ? nzd(r[k]) : null);
|
|
197
|
+
const figure = shown
|
|
198
|
+
? `${place.name} (${kind}), tenancies begun in ${feed.month_words}: median ${nzd(r.median_weekly_rent_nzd)} a week, ` +
|
|
199
|
+
`from ${Number(r.new_bonds).toLocaleString("en-NZ")} new bonds` +
|
|
200
|
+
(money("geometric_mean_weekly_rent_nzd") ? `; geometric mean ${money("geometric_mean_weekly_rent_nzd")}` : "") +
|
|
201
|
+
(money("lower_quartile_weekly_rent_nzd") && money("upper_quartile_weekly_rent_nzd")
|
|
202
|
+
? `; MBIE's lower and upper quartile rents ${money("lower_quartile_weekly_rent_nzd")} and ` +
|
|
203
|
+
`${money("upper_quartile_weekly_rent_nzd")}` : "") +
|
|
204
|
+
`.${small ? ` Small sample (under ${NZ_SMALL} new bonds): treat with caution.` : ""}`
|
|
205
|
+
: `${place.name} (${kind}), ${feed.month_words}: no figure. MBIE publishes none where fewer than ${NZ_MIN_BONDS} ` +
|
|
206
|
+
"bonds were lodged.";
|
|
207
|
+
const text = [
|
|
208
|
+
...staleNote(env),
|
|
209
|
+
`New Zealand rents, in New Zealand dollars (NZ$), not Australian dollars: MBIE's median weekly rent of the bonds ` +
|
|
210
|
+
// What the code knows (the re-review of #91): a bundled or offline copy can be older than MBIE's latest month.
|
|
211
|
+
`for private tenancies that began in ${feed.month_words}. It is the latest month in DwellDelta's copy of MBIE's ` +
|
|
212
|
+
"data, which MBIE can revise as bonds lodged late are recorded. " +
|
|
213
|
+
`Provisional: ${nzWords(feed.change_withheld ?? "no change on a year is given")}.`,
|
|
214
|
+
"",
|
|
215
|
+
figure,
|
|
216
|
+
"These are rents of new bonds lodged with Tenancy Services, not advertised rents and not what sitting tenants " +
|
|
217
|
+
"pay. Nothing here is set beside an Australian figure.",
|
|
218
|
+
"",
|
|
219
|
+
"Limits:",
|
|
220
|
+
...feed.limits.map((l) => "- " + nzWords(l)),
|
|
221
|
+
"",
|
|
222
|
+
...(url ? [`Page: ${url}`] : []),
|
|
223
|
+
...(cite ? [`Cite as: ${cite}`] : []),
|
|
224
|
+
/^Source:/.test(feed.attribution) ? feed.attribution : `Source: ${feed.attribution}`,
|
|
225
|
+
citeLine({ source: feed.source, period: `${feed.month_words} (provisional)`, licence: feed.licence,
|
|
226
|
+
n: shown ? `${r.new_bonds} new bonds` : `fewer than ${NZ_MIN_BONDS} new bonds (withheld)`,
|
|
227
|
+
url: env.sources[0].source_url ?? MBIE_PAGE(feed), feedUrl: PUBLISHED_BASE + NZ_FILE, stale: flagged(env) }),
|
|
228
|
+
FOOTER,
|
|
229
|
+
].join("\n");
|
|
230
|
+
const row = Object.fromEntries(Object.entries(r).filter(([k]) => k !== "area" && k !== "region"));
|
|
231
|
+
return {
|
|
232
|
+
text,
|
|
233
|
+
structured: { ...env, country: "NZ", currency: "NZD", unit: feed.unit ?? "NZD per week", provisional: true,
|
|
234
|
+
month: feed.month, month_words: feed.month_words, change_withheld: feed.change_withheld ?? null,
|
|
235
|
+
nz_place: { name: place.name, kind: place.kind === "region" ? "region" : "territorial_authority", ...row,
|
|
236
|
+
shown, small_sample: small },
|
|
237
|
+
limits: feed.limits.filter((l) => typeof l === "string"), page_url: url, cite_as: cite },
|
|
238
|
+
};
|
|
239
|
+
}
|
|
240
|
+
|
|
241
|
+
// --- The ACT, the Northern Territory and Tasmania: interim ABS cover ----------------------------------------------------
|
|
242
|
+
|
|
243
|
+
const MONTHS = ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October",
|
|
244
|
+
"November", "December"];
|
|
245
|
+
const longDate = (iso) => `${Number(iso.slice(8, 10))} ${MONTHS[Number(iso.slice(5, 7)) - 1]} ${iso.slice(0, 4)}`;
|
|
246
|
+
const longMonth = (ym) => `${MONTHS[Number(String(ym).slice(5, 7)) - 1]} ${String(ym).slice(0, 4)}`;
|
|
247
|
+
const aud = (v) => `$${Number(v).toLocaleString("en-AU")}`;
|
|
248
|
+
const signed = (v) => `${v >= 0 ? "+" : ""}${v}%`;
|
|
249
|
+
export const interimPage = (state) => `${SITE}/area/${INTERIM[state].page}/`;
|
|
250
|
+
/** "Census night, 10 August 2021": the period every Census figure carries. */
|
|
251
|
+
export const censusPeriod = (feed) => `Census night, ${longDate(feed.census_2021.census_date)}`;
|
|
252
|
+
|
|
253
|
+
/** The flags a postal area carries, in the site's words. */
|
|
254
|
+
export function interimFlags(r) {
|
|
255
|
+
const out = [];
|
|
256
|
+
if (r.mostly_not_private_rentals === true) out.push(INTERIM_FLAGS.mostly);
|
|
257
|
+
if (r.small_census_sample) out.push(INTERIM_FLAGS.small);
|
|
258
|
+
if (r.census_2021_median_weekly_rent_aud == null) {
|
|
259
|
+
const why = r.census_2021_no_median ?? "the ABS publishes no median rent for this postal area";
|
|
260
|
+
out.push(`${why[0].toUpperCase()}${why.slice(1)}.`);
|
|
261
|
+
} else if (Number.isFinite(r.census_2021_renting_households_rent_stated) && r.census_2021_renting_households_rent_stated < INTERIM_FEW) {
|
|
262
|
+
out.push(`Too few households for a median (${r.census_2021_renting_households_rent_stated}).`);
|
|
263
|
+
}
|
|
264
|
+
if (r.crosses_border) out.push(`Crosses a border: ${r.crosses_border}.`);
|
|
265
|
+
return out;
|
|
266
|
+
}
|
|
267
|
+
const interimShown = (r) => r.census_2021_median_weekly_rent_aud != null
|
|
268
|
+
&& !(Number.isFinite(r.census_2021_renting_households_rent_stated) && r.census_2021_renting_households_rent_stated < INTERIM_FEW);
|
|
269
|
+
|
|
270
|
+
/**
|
|
271
|
+
* One interim answer: a postal area's 2021 Census rent (postcode given), or none (the state or its capital asked), with
|
|
272
|
+
* the capital's rents index and the sale medians, each with its period. Never a bond median, never another state.
|
|
273
|
+
*/
|
|
274
|
+
export function interimResult(state, feed, postcode = null, now = new Date()) {
|
|
275
|
+
const info = INTERIM[state];
|
|
276
|
+
const c = feed.census_2021, cpi = feed.cpi_rents, px = feed.dwelling_prices;
|
|
277
|
+
const census = censusPeriod(feed);
|
|
278
|
+
const row = postcode ? c.postcodes.filter(isRecord).find((r) => r.postcode === postcode) : null;
|
|
279
|
+
if (postcode && !row) {
|
|
280
|
+
throw new ToolError(`Postcode ${postcode} is in ${info.name}, but the ABS's 2021 Census has no postal area ${postcode} ` +
|
|
281
|
+
"in DwellDelta's interim file (a PO Box or other non-residential postcode has none).",
|
|
282
|
+
`Give a residential postcode, or ${JSON.stringify(state)} alone for ${cpi.city}'s rents index and the sale prices. ` +
|
|
283
|
+
`Every postal area held is listed at ${interimPage(state)}`);
|
|
284
|
+
}
|
|
285
|
+
const src = (source, period) => ({ ...feedSource(feed, PUBLISHED_BASE + info.file, period), source });
|
|
286
|
+
// "Rest of NT" as a sentence says it: "the rest of the Northern Territory" (capitalised to open a line).
|
|
287
|
+
const regionWords = (region, opening = true) => (/^Rest of /.test(region)
|
|
288
|
+
? `${opening ? "The" : "the"} rest of ${info.name}` : region);
|
|
289
|
+
const env = envelope({ sources: [src(c.source, census), src(cpi.source, cpi.period), src(px.source, px.period)],
|
|
290
|
+
dataAsOf: cpi.latest_month, origin: feed.origin ?? null, cadence: CADENCE.interim_cpi }, now);
|
|
291
|
+
const flags = row ? interimFlags(row) : [];
|
|
292
|
+
const shown = row ? interimShown(row) : false;
|
|
293
|
+
const n = (v) => Number(v).toLocaleString("en-AU");
|
|
294
|
+
const censusLine = !row
|
|
295
|
+
? `2021 Census rents are by postal area (${c.postcodes.length} in this file): give a postcode for one.`
|
|
296
|
+
: row.census_2021_median_weekly_rent_aud == null
|
|
297
|
+
? `Postal area ${postcode}, ${census}: no median.`
|
|
298
|
+
: !shown
|
|
299
|
+
? `Postal area ${postcode}, ${census}: Too few households for a median (${row.census_2021_renting_households_rent_stated}).`
|
|
300
|
+
: `Postal area ${postcode}, ${census}: median weekly rent paid ${aud(row.census_2021_median_weekly_rent_aud)}` +
|
|
301
|
+
`${row.mostly_not_private_rentals === true ? " (not a market rent)" : ""}, by the ` +
|
|
302
|
+
// The share's base is the households whose landlord type was stated (dwelldelta-local
|
|
303
|
+
// build_interim_rents_feeds.py: the sum of G40's five landlord-type cells), not those who stated their rent.
|
|
304
|
+
`${n(row.census_2021_renting_households_rent_stated)} renting households who stated their rent, on leases new ` +
|
|
305
|
+
"and old, every landlord type, social housing included" + (Number.isFinite(row.census_2021_private_landlord_share_pct)
|
|
306
|
+
? `; ${row.census_2021_private_landlord_share_pct}% of those whose landlord type was stated rented from an ` +
|
|
307
|
+
"agent or a private landlord." : ".");
|
|
308
|
+
const only = px.places.length > 1 ? ` It is for ${cpi.city} only.` : "";
|
|
309
|
+
const prices = px.places.filter(isRecord).map((p) => {
|
|
310
|
+
const l = p.latest ?? {};
|
|
311
|
+
const part = (what, price, count) => (Number.isFinite(l[price]) ? `${what} ${aud(l[price])}` +
|
|
312
|
+
(Number.isFinite(l[count]) ? ` (${n(l[count])} transfers)` : "") : `${what}: none published`);
|
|
313
|
+
return `- ${regionWords(p.region)}: ${part("established houses", "median_price_established_houses_aud", "established_house_transfers")}; ` +
|
|
314
|
+
`${part("attached dwellings", "median_price_attached_dwellings_aud", "attached_dwelling_transfers")}.`;
|
|
315
|
+
});
|
|
316
|
+
const placeNames = px.places.filter(isRecord).map((p) => regionWords(p.region, false));
|
|
317
|
+
const priceHeading = `Median sale prices for ${placeNames.join(" and ")} as a whole (ABS; sales, not rents; not for ` +
|
|
318
|
+
`${postcode ? `postal area ${postcode}` : "any suburb or postcode"}), ${px.period}; the ABS revises the latest ` +
|
|
319
|
+
"quarter:";
|
|
320
|
+
const cite = `Interim rent cover, ${info.name.replace(/^the /, "")}: 2021 Census median weekly rents by postal area ` +
|
|
321
|
+
`(${census}), the ABS rents index for ${cpi.city} (${cpi.year_change_period}) and ABS median sale prices ` +
|
|
322
|
+
`(${px.period}). Source: ${feed.rights_holder}, ${feed.licence}. Via DwellDelta: ${interimPage(state)}`;
|
|
323
|
+
const text = [
|
|
324
|
+
...staleNote(env),
|
|
325
|
+
`Interim cover for ${info.name}, from ABS data. DwellDelta holds no rents from new bonds for ${info.name}: none ` +
|
|
326
|
+
"of these figures is a median of new bonds, and none is today's rent. Do not carry the 2021 rent forward with " +
|
|
327
|
+
// The ABS index is far older than this file's monthly series; the site's renderer says the same (re-review of #91).
|
|
328
|
+
`the rents index (the monthly series in this file starts in ${longMonth(cpi.first_month)}, is for ${cpi.city} as a ` +
|
|
329
|
+
"whole, and covers all " +
|
|
330
|
+
"tenancies), and do not divide a rent by a sale price: no current rent and no rental yield can be read from these " +
|
|
331
|
+
"figures.",
|
|
332
|
+
"",
|
|
333
|
+
censusLine,
|
|
334
|
+
...flags.filter((f) => !/^Too few households/.test(f)).map((f) => ` ${f}`),
|
|
335
|
+
`${cpi.city}'s rents index (ABS CPI: the change in rents paid for the same homes, on new and continuing leases, ` +
|
|
336
|
+
"private and public housing, net of Rent Assistance; not a rent): " +
|
|
337
|
+
`${signed(cpi.year_change_pct)} from ${cpi.year_change_period}, ${signed(cpi.change_since_first_month_pct)} from ` +
|
|
338
|
+
`${cpi.change_since_first_month_period}.${only}`,
|
|
339
|
+
priceHeading,
|
|
340
|
+
...prices,
|
|
341
|
+
"Nothing here is set beside another state's figures or New Zealand's.",
|
|
342
|
+
"",
|
|
343
|
+
"Limits:",
|
|
344
|
+
...feed.limits.map((l) => "- " + l),
|
|
345
|
+
"",
|
|
346
|
+
`Page: ${interimPage(state)}`,
|
|
347
|
+
`Cite as: ${cite}`,
|
|
348
|
+
`Source: ${feed.attribution}`,
|
|
349
|
+
FOOTER,
|
|
350
|
+
].join("\n");
|
|
351
|
+
const pa = row ? { ...row, census_2021_median_weekly_rent_aud: shown ? row.census_2021_median_weekly_rent_aud : null,
|
|
352
|
+
median_shown: shown, flags } : null;
|
|
353
|
+
return {
|
|
354
|
+
text,
|
|
355
|
+
structured: { ...env, interim: true, measure: "interim_rent_cover", state_name: info.name.replace(/^the /, ""),
|
|
356
|
+
periods: feed.periods ?? null, census_period: census, postal_area: pa,
|
|
357
|
+
cpi_rents: cpi, dwelling_prices: px, limits: feed.limits.filter((l) => typeof l === "string"),
|
|
358
|
+
page_url: interimPage(state), cite_as: cite },
|
|
359
|
+
};
|
|
360
|
+
}
|
package/output-schemas.mjs
CHANGED
|
@@ -275,7 +275,14 @@ export const OUTPUT_SCHEMAS = {
|
|
|
275
275
|
|
|
276
276
|
// property_rents (0.12.0, place-tool.mjs): the answer of area_rents or vic_rents for the state that holds the
|
|
277
277
|
// place, as that tool gives it (allowed as every unnamed key is), and resolved_state and resolved_place: the state
|
|
278
|
-
// and the place in words the question was read as.
|
|
278
|
+
// and the place in words the question was read as. From 0.14.0 (cover-tool.mjs), two more kinds of answer, in keys
|
|
279
|
+
// of their own, allowed as every unnamed key is: New Zealand (resolved_state "NZ"; country "NZ", currency "NZD",
|
|
280
|
+
// provisional true, month, nz_place with MBIE's fields ending _nzd), and interim ABS cover (resolved_state ACT, NT
|
|
281
|
+
// or TAS; interim true, census_period, postal_area with the file's census_2021_* fields and its flags, cpi_rents,
|
|
282
|
+
// dwelling_prices). At the top level neither carries a key the new-bond answers give a meaning (median_weekly_rent_aud,
|
|
283
|
+
// new_bonds, quarter...); nz_place nests MBIE's own row, whose new_bonds, change_pct and small_sample are MBIE's (in
|
|
284
|
+
// NZ$, change_pct null while provisional), and the interim answer carries none of them anywhere. No released field
|
|
285
|
+
// changes meaning: the new answers are told apart by resolved_state and by country or interim.
|
|
279
286
|
property_rents: obj({ ...envelope, resolved_state: str, resolved_place: str }),
|
|
280
287
|
|
|
281
288
|
// Two answers: the consent text and token (stored: false), or the deletion code once the rent is added (stored:
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "dwelldelta-mcp",
|
|
3
|
-
"version": "0.
|
|
4
|
-
"description": "Australian rents by area for five states, asked by place with no state, a rent placed against its local median, NSW median sale prices, an ABS rents index check, and sourced property and lending indicators, for AI agents.",
|
|
3
|
+
"version": "0.15.0",
|
|
4
|
+
"description": "Australian rents by area for five states, New Zealand rents by council and region and interim ABS cover for the ACT, NT and Tasmania, asked by place with no state, a rent placed against its local median, NSW median sale prices, an ABS rents index check, and sourced property and lending indicators, for AI agents.",
|
|
5
5
|
"mcpName": "au.com.dwelldelta/dwelldelta",
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"homepage": "https://dwelldelta.com.au/",
|
|
@@ -29,6 +29,7 @@
|
|
|
29
29
|
"sale-prices-tool.mjs",
|
|
30
30
|
"pages.mjs",
|
|
31
31
|
"place-tool.mjs",
|
|
32
|
+
"cover-tool.mjs",
|
|
32
33
|
"vendor/",
|
|
33
34
|
"LICENSE",
|
|
34
35
|
"README.md"
|