sketch a different API for type-safe string format