@code-yeongyu/senpi
Version:
Coding agent CLI with read, bash, edit, write tools and session management
23 lines • 1.4 kB
TypeScript
export interface HostProcessMetrics {
/** Resident memory of the daemon's process tree, in megabytes; shared pages count once per process. */
readonly rss_mb: number | null;
/**
* Resident memory of the daemon's OWN processes - the lifecycle supervisor and the session host
* it runs - without the tools, kernels and servers its sessions spawned. It is the number `ps`
* shows for those pids and the one the host's memory sampler reads (senpi#2207).
*/
readonly host_rss_mb: number | null;
/**
* Memory footprint of the same supervisor and host processes, read from the kernel counter the host's
* own sampler uses (`phys_footprint` on macOS, `RssAnon` on Linux). Unlike RSS it keeps counting pages
* that were compressed or swapped out, so a host that RSS shows at 1.3 GB can be holding 14 GB
* (senpi#3110). `null` when any of those processes has no readable counter.
*/
readonly host_footprint_mb: number | null;
/** Open descriptors across the tree. `/proc`-only, so `null` off Linux. */
readonly open_fds: number | null;
/** Processes in the tree that have exited and whose status nobody collected. */
readonly zombies: number | null;
}
export declare function readHostProcessMetrics(pid: number, platform?: NodeJS.Platform): Promise<HostProcessMetrics>;
//# sourceMappingURL=host-process-metrics.d.ts.map