Concept:
A function is differentiable at a point only if:
• It is continuous at that point.
• The left-hand derivative equals the right-hand derivative.
Since the function changes its definition at \(x=-1\) and \(x=1\), differentiability must be checked at both points.
Step 1: Continuity at \(x=1\).
From the left side,
\[
\lim_{x\to1^-}(x^2+b)
=
1+b.
\]
From the right side,
\[
\lim_{x\to1^+}\frac{a}{|x|}
=
a.
\]
Continuity gives
\[
1+b=a.
\]
\[
a-b=1.
\]
Step 2: Differentiate both branches.
For \(-1<x<1\),
\[
f(x)=x^2+b.
\]
Thus,
\[
f'(x)=2x.
\]
At \(x=1\),
\[
f'_-(1)=2.
\]
For \(x>1\),
\[
f(x)=\frac{a}{x}.
\]
Hence,
\[
f'(x)
=
-\frac{a}{x^2}.
\]
Therefore,
\[
f'_+(1)
=
-a.
\]
Differentiability gives
\[
2=-a.
\]
Thus,
\[
a=-2.
\]
Step 3: Determine \(b\).
Using
\[
1+b=a,
\]
we get
\[
1+b=-2.
\]
Hence,
\[
b=-3.
\]
Step 4: Calculate \(a+b\).
\[
a+b
=
(-2)+(-3)
=
-5.
\]
Therefore,
\[
\boxed{-5}.
\]