```ts
export function stampCover(label: string, dies: [string, number][]): number {
  if (typeof label !== 'string' || label === '') {
    throw new Error('Label must be a non-empty string');
  }

  const dieTable = stampTable(dies);

  if (!dieTable.has(label)) {
    throw new Error(`No sequence of dies can spell the label "${label}"`);
  }

  const minCost: number[] = Array.from({ length: label.length + 1 }, () => Infinity);
  minCost[0] = 0;

  for (let i = 1; i <= label.length; i++) {
    for (const [fragment, price] of dieTable.entries()) {
      if (label.slice(i - fragment.length) === fragment) {
        minCost[i] = Math.min(minCost[i], minCost[i - fragment.length] + price);
      }
    }
  }

  return minCost[label.length];
}

export function stampTable(dies: [string, number][]): Map<string, number> {
  const table = new Map<string, number>();

  for (const [fragment, price] of dies) {
    if (typeof fragment !== 'string' || fragment === '') {
      throw new Error('Fragment must be a non-empty string');
    }
    if (typeof price !== 'number' || price <= 0 || !Number.isInteger(price)) {
      throw new Error('Price must be a positive integer');
    }
    if (table.has(fragment)) {
      throw new Error(`Fragment "${fragment}" is listed twice`);
    }

    table.set(fragment, price);
  }

  return table;
}
```